From 32937c53d14868ba162b6524937a675555661916 Mon Sep 17 00:00:00 2001 From: Uku Taht Date: Fri, 6 Mar 2020 11:11:38 +0200 Subject: [PATCH] Upgrade tailwind to 1.2.0 (#42) * Upgrade config file * Upgrade grey colour * Update styles for dashboard * Update styles for new site flow * Update styles for user settings * Update site setting styles * Update other pages * Adjust spacing * Update last grey rules * Purge css --- assets/css/app.css | 30 +- assets/css/modal.css | 6 - assets/js/dashboard/datepicker.js | 19 +- assets/js/dashboard/filters.js | 2 +- assets/js/dashboard/index.js | 2 +- assets/js/dashboard/stats/bar.js | 5 +- assets/js/dashboard/stats/conversions.js | 8 +- assets/js/dashboard/stats/countries.js | 2 +- assets/js/dashboard/stats/current-visitors.js | 4 +- assets/js/dashboard/stats/devices.js | 40 +- assets/js/dashboard/stats/modals/countries.js | 11 +- .../dashboard/stats/modals/google-keywords.js | 24 +- assets/js/dashboard/stats/modals/pages.js | 12 +- .../stats/modals/referrer-drilldown.js | 28 +- assets/js/dashboard/stats/modals/referrers.js | 14 +- assets/js/dashboard/stats/more-link.js | 6 +- assets/js/dashboard/stats/pages.js | 10 +- assets/js/dashboard/stats/referrers.js | 12 +- assets/js/dashboard/stats/visitor-graph.js | 12 +- assets/package-lock.json | 600 ++++------- assets/package.json | 3 +- assets/postcss.config.js | 16 +- assets/tailwind.config.js | 52 + assets/tailwind.js | 963 ------------------ lib/plausible/auth/user.ex | 2 +- .../templates/auth/login_form.html.eex | 20 +- .../templates/auth/password_form.html.eex | 10 +- .../auth/password_reset_form.html.eex | 12 +- .../auth/password_reset_request_form.html.eex | 8 +- .../password_reset_request_success.html.eex | 8 +- .../templates/auth/register_form.html.eex | 20 +- .../templates/auth/register_success.html.eex | 8 +- .../templates/auth/user_settings.html.eex | 52 +- .../templates/billing/change_plan.html.eex | 18 +- .../templates/billing/upgrade.html.eex | 16 +- .../templates/error/error.html.eex | 2 +- .../templates/layout/_footer.html.eex | 6 +- .../templates/layout/app.html.eex | 30 +- .../templates/layout/focus.html.eex | 6 +- .../templates/page/contact_form.html.eex | 12 +- .../templates/page/contact_thanks.html.eex | 6 +- .../templates/page/data_policy.html.eex | 18 +- .../templates/page/index.html.eex | 147 ++- .../templates/page/privacy.html.eex | 2 +- .../templates/page/sites.html.eex | 18 +- .../templates/page/terms.html.eex | 24 +- .../site/custom_domain_dns_setup.html.eex | 8 +- .../site/custom_domain_snippet.html.eex | 18 +- lib/plausible_web/templates/site/new.html.eex | 20 +- .../templates/site/new_custom_domain.html.eex | 10 +- .../templates/site/new_goal.html.eex | 14 +- .../templates/site/new_shared_link.html.eex | 8 +- .../templates/site/settings.html.eex | 166 ++- .../templates/site/snippet.html.eex | 12 +- .../stats/shared_link_password.html.eex | 10 +- .../templates/stats/stats.html.eex | 2 +- .../stats/waiting_first_pageview.html.eex | 12 +- .../templates/unsubscribe/success.html.eex | 2 +- lib/plausible_web/views/error_helpers.ex | 2 +- lib/plausible_web/views/stats_view.ex | 2 +- 60 files changed, 707 insertions(+), 1905 deletions(-) create mode 100644 assets/tailwind.config.js delete mode 100644 assets/tailwind.js diff --git a/assets/css/app.css b/assets/css/app.css index bb89467fa..0d8344c7b 100644 --- a/assets/css/app.css +++ b/assets/css/app.css @@ -1,11 +1,13 @@ -@tailwind preflight; +/* purgecss start ignore */ +@tailwind base; @tailwind components; +/* purgecss end ignore */ @import "modal.css"; @import "loader.css"; @import "tooltip.css"; .button { - @apply inline-block bg-indigo text-white text-center font-bold tracking-wide py-3 px-5 rounded no-underline; + @apply inline-block bg-indigo-600 text-white text-center font-bold tracking-wide py-2 px-5 rounded no-underline; } .button:hover { @@ -17,7 +19,7 @@ } .button-outline { - @apply bg-transparent border border-indigo text-indigo; + @apply bg-transparent border border-indigo-600 text-indigo-600; } .button-sm { @@ -29,7 +31,7 @@ } html { - @apply font-sans text-grey-darkest; + @apply text-gray-800; } body { @@ -37,12 +39,8 @@ body { -moz-osx-font-smoothing: grayscale; } -a, button { - @apply no-underline; -} - blockquote { - @apply my-4 py-2 px-4 border-l-4 border-grey; + @apply my-4 py-2 px-4 border-l-4 border-gray-500; } @screen xl { @@ -85,10 +83,6 @@ blockquote { } } -a { - color: inherit; -} - .light-text { color: #F0F4F8; } @@ -118,7 +112,7 @@ a { border-radius: 45px; background-color: #01a4e9; animation: pulse-ring 1.25s cubic-bezier(0.215, 0.61, 0.355, 1) infinite; - @apply bg-green; + @apply bg-green-500; } .pulsating-circle:after { content: ''; @@ -131,7 +125,7 @@ a { background-color: white; border-radius: 15px; animation: pulse-dot 1.25s cubic-bezier(0.455, 0.03, 0.515, 0.955) -.4s infinite; - @apply bg-green; + @apply bg-green-500; } @@ -193,15 +187,15 @@ a { .feather { height: 1em; width: 1em; - transform: translateY(0.15em); overflow: visible; + display: inline; } .feather-sm { height: 1em; width: 1em; - transform: translateY(0.05em); overflow: visible; + display: inline; } .table-striped tbody tr:nth-child(odd) { @@ -219,7 +213,7 @@ a { } .tweet-text a { - @apply text-blue; + @apply text-blue-500; } .tweet-text a:hover { diff --git a/assets/css/modal.css b/assets/css/modal.css index a754ac2e7..10028c9ea 100644 --- a/assets/css/modal.css +++ b/assets/css/modal.css @@ -46,12 +46,6 @@ transition: height 200ms ease-in; } -.modal__header { - display: flex; - justify-content: space-between; - align-items: center; -} - .modal__close { position: fixed; color: #b8c2cc; diff --git a/assets/js/dashboard/datepicker.js b/assets/js/dashboard/datepicker.js index 62b65ee59..10a6b07cb 100644 --- a/assets/js/dashboard/datepicker.js +++ b/assets/js/dashboard/datepicker.js @@ -1,7 +1,6 @@ import React from 'react'; import { withRouter, Link } from 'react-router-dom' import Flatpickr from "react-flatpickr"; -import "flatpickr/dist/themes/airbnb.css"; import {shiftDays, shiftMonths, formatDay, formatDayShort, formatMonthYYYY, formatISO, isToday} from './date' @@ -96,7 +95,7 @@ class DatePicker extends React.Component { renderArrow(period, prevDate, nextDate) { return (
- + @@ -133,9 +132,9 @@ class DatePicker extends React.Component { renderDropDown() { return (
this.dropDownNode = node}> -
+
{this.timeFrameText()} - +
@@ -159,7 +158,7 @@ class DatePicker extends React.Component { } return ( - + {text} ) @@ -169,24 +168,24 @@ class DatePicker extends React.Component { if (this.state.mode === 'open') { return (
-
+
{ this.renderLink('day', 'Today') }
-
+
{ this.renderLink('7d', 'Last 7 days') } { this.renderLink('30d', 'Last 30 days') } { this.renderLink('60d', 'Last 60 days') }
-
+
{ this.renderLink('6mo', 'Last 6 months') } { this.renderLink('12mo', 'Last 12 months') }
-
+
- this.setState({mode: 'calendar'}, this.openCalendar.bind(this))} className="block px-4 py-2 text-sm leading-tight hover:bg-grey-lightest hover:text-black cursor-pointer">Custom range + this.setState({mode: 'calendar'}, this.openCalendar.bind(this))} className="block px-4 py-2 text-sm leading-tight hover:bg-gray-100 hover:text-gray-900 cursor-pointer">Custom range
diff --git a/assets/js/dashboard/filters.js b/assets/js/dashboard/filters.js index a76d7a141..46d617b61 100644 --- a/assets/js/dashboard/filters.js +++ b/assets/js/dashboard/filters.js @@ -10,7 +10,7 @@ function Filters({query, history, location}) { return (
- + Completed goal {query.filters.goal} ✕
diff --git a/assets/js/dashboard/index.js b/assets/js/dashboard/index.js index 64b30113d..c7f814c1b 100644 --- a/assets/js/dashboard/index.js +++ b/assets/js/dashboard/index.js @@ -47,7 +47,7 @@ class Stats extends React.Component {
-

Analytics for {this.props.site.domain}

+

Analytics for {this.props.site.domain}

diff --git a/assets/js/dashboard/stats/bar.js b/assets/js/dashboard/stats/bar.js index fd69897ed..e38b67845 100644 --- a/assets/js/dashboard/stats/bar.js +++ b/assets/js/dashboard/stats/bar.js @@ -10,12 +10,11 @@ function barWidth(count, all) { return count / maxVal * 100 } -export default function Bar({count, all, color}) { - color = color ? color : "blue" +export default function Bar({count, all, bg}) { const width = barWidth(count, all) return ( -
+
) } diff --git a/assets/js/dashboard/stats/conversions.js b/assets/js/dashboard/stats/conversions.js index 81f68ef13..866df3c38 100644 --- a/assets/js/dashboard/stats/conversions.js +++ b/assets/js/dashboard/stats/conversions.js @@ -35,8 +35,8 @@ export default class Conversions extends React.Component { return (
- - { goal.name } + + { goal.name }
{numberFormatter(goal.count)}
@@ -53,8 +53,8 @@ export default class Conversions extends React.Component { } else if (this.state.goals) { return (
-

Goal Conversions

-
+

Goal Conversions

+
Goal Conversions
diff --git a/assets/js/dashboard/stats/countries.js b/assets/js/dashboard/stats/countries.js index 002bcfcfa..71369c3d1 100644 --- a/assets/js/dashboard/stats/countries.js +++ b/assets/js/dashboard/stats/countries.js @@ -84,7 +84,7 @@ export default class Countries extends React.Component { if (this.state.countries) { return ( -

Countries

+

Countries

diff --git a/assets/js/dashboard/stats/current-visitors.js b/assets/js/dashboard/stats/current-visitors.js index ebda9e17b..c81bb66dc 100644 --- a/assets/js/dashboard/stats/current-visitors.js +++ b/assets/js/dashboard/stats/current-visitors.js @@ -27,8 +27,8 @@ export default class CurrentVisitors extends React.Component { render() { if (this.state.currentVisitors !== null) { return ( -
- +
+ {this.state.currentVisitors} current visitors diff --git a/assets/js/dashboard/stats/devices.js b/assets/js/dashboard/stats/devices.js index 4b931d822..04aa46fdc 100644 --- a/assets/js/dashboard/stats/devices.js +++ b/assets/js/dashboard/stats/devices.js @@ -21,19 +21,19 @@ const EXPLANATION = { function iconFor(screenSize) { if (screenSize === 'Mobile') { return ( - + ) } else if (screenSize === 'Tablet') { return ( - + ) } else if (screenSize === 'Laptop') { return ( - + ) } else if (screenSize === 'Desktop') { return ( - + ) } } @@ -64,8 +64,8 @@ class ScreenSizes extends React.Component { return (
- - {iconFor(size.name)} {size.name} + + {iconFor(size.name)} {size.name}
{size.percentage}%
@@ -76,7 +76,7 @@ class ScreenSizes extends React.Component { if (this.state.sizes && this.state.sizes.length > 0) { return ( -
+
Screen size Visitors
@@ -84,7 +84,7 @@ class ScreenSizes extends React.Component { ) } else { - return
No data yet
+ return
No data yet
} } @@ -126,8 +126,8 @@ class Browsers extends React.Component { return (
- - {browser.name} + + {browser.name}
{browser.percentage}%
@@ -138,7 +138,7 @@ class Browsers extends React.Component { if (this.state.browsers && this.state.browsers.length > 0) { return ( -
+
Browser Visitors
@@ -146,7 +146,7 @@ class Browsers extends React.Component { ) } else { - return
No data yet
+ return
No data yet
} } @@ -188,8 +188,8 @@ class OperatingSystems extends React.Component { return (
- - {os.name} + + {os.name}
{os.percentage}%
@@ -200,7 +200,7 @@ class OperatingSystems extends React.Component { if (this.state.operatingSystems && this.state.operatingSystems.length > 0) { return ( -
+
Operating system Visitors
@@ -208,7 +208,7 @@ class OperatingSystems extends React.Component { ) } else { - return
No data yet
+ return
No data yet
} } @@ -248,12 +248,12 @@ export default class Devices extends React.Component { renderPill(name, mode) { const isActive = this.state.mode === mode - const extraClass = name === 'OS' ? '' : ' border-r border-grey-light' + const extraClass = name === 'OS' ? '' : ' border-r border-gray-400' if (isActive) { return {name} } else { - return {name} + return {name} } } @@ -261,9 +261,9 @@ export default class Devices extends React.Component { return (
-

Devices

+

Devices

-
+
{ this.renderPill('Size', 'size') } { this.renderPill('Browser', 'browser') } { this.renderPill('OS', 'os') } diff --git a/assets/js/dashboard/stats/modals/countries.js b/assets/js/dashboard/stats/modals/countries.js index f545e23f8..b0baca0d5 100644 --- a/assets/js/dashboard/stats/modals/countries.js +++ b/assets/js/dashboard/stats/modals/countries.js @@ -37,18 +37,15 @@ class CountriesModal extends React.Component { } else if (this.state.countries) { return ( -
-

Top countries

-
-
by visitors
+

Top countries

-
+
- - + + diff --git a/assets/js/dashboard/stats/modals/google-keywords.js b/assets/js/dashboard/stats/modals/google-keywords.js index 1672ca374..6454d77f9 100644 --- a/assets/js/dashboard/stats/modals/google-keywords.js +++ b/assets/js/dashboard/stats/modals/google-keywords.js @@ -43,7 +43,7 @@ class GoogleKeywordsModal extends React.Component { renderKeywords() { if (this.state.query.filters.goal) { return ( -
+
Sorry, we cannot show which keywords converted best for goal {this.state.query.filters.goal}
Google does not share this information
@@ -52,7 +52,7 @@ class GoogleKeywordsModal extends React.Component { } else if (this.state.notConfigured) { if (this.state.isOwner) { return ( -
+
The site is not connected to Google Search Keywords
Configure the integration to view search terms
@@ -61,7 +61,7 @@ class GoogleKeywordsModal extends React.Component { ) } else { return ( -
+
The site is not connected to Google Search Kewyords
Cannot show search terms
@@ -73,8 +73,8 @@ class GoogleKeywordsModal extends React.Component {
CountryVisitorsCountryVisitors
- - + + @@ -84,7 +84,7 @@ class GoogleKeywordsModal extends React.Component { ) } else { return ( -
+
Could not find any search terms for this period
@@ -100,14 +100,12 @@ class GoogleKeywordsModal extends React.Component { } else { return ( -
- ← All referrers -
+ ← All referrers -
-
-

{this.state.totalVisitors} new visitors from Google

-

{toHuman(this.state.query)}

+
+
+

{this.state.totalVisitors} new visitors from Google

+

{toHuman(this.state.query)}

{ this.renderKeywords() }
diff --git a/assets/js/dashboard/stats/modals/pages.js b/assets/js/dashboard/stats/modals/pages.js index 910811faf..7f3438ae1 100644 --- a/assets/js/dashboard/stats/modals/pages.js +++ b/assets/js/dashboard/stats/modals/pages.js @@ -52,18 +52,16 @@ class PagesModal extends React.Component { } else if (this.state.pages) { return ( -
-

Top pages

-
+

Top pages

-
+
Search TermVisitorsSearch TermVisitors
- - - {this.showBounceRate() && } + + + {this.showBounceRate() && } diff --git a/assets/js/dashboard/stats/modals/referrer-drilldown.js b/assets/js/dashboard/stats/modals/referrer-drilldown.js index 61fd17519..18d8dcc51 100644 --- a/assets/js/dashboard/stats/modals/referrer-drilldown.js +++ b/assets/js/dashboard/stats/modals/referrer-drilldown.js @@ -51,7 +51,7 @@ class ReferrerDrilldownModal extends React.Component { renderTweet(tweet, index) { const authorUrl = `https://twitter.com/${tweet.author_handle}` const tweetUrl = `${authorUrl}/status/${tweet.tweet_id}` - const border = index === 0 ? '' : ' pt-4 border-t border-grey-light' + const border = index === 0 ? '' : ' pt-4 border-t border-gray-300' return (
@@ -59,15 +59,15 @@ class ReferrerDrilldownModal extends React.Component {
-
{tweet.author_name}
-
@{tweet.author_handle}
+
{tweet.author_name}
+
@{tweet.author_handle}
-
+
{formatFullDate(new Date(tweet.created))}
@@ -80,10 +80,10 @@ class ReferrerDrilldownModal extends React.Component { @@ -107,7 +107,7 @@ class ReferrerDrilldownModal extends React.Component { renderGoalText() { if (this.state.query.filters.goal) { return ( -

completed {this.state.query.filters.goal}

+

completed {this.state.query.filters.goal}

) } } @@ -120,21 +120,19 @@ class ReferrerDrilldownModal extends React.Component { } else if (this.state.referrers) { return ( -
- ← All referrers -
+ ← All referrers -
+
-

{this.state.totalVisitors} visitors from {this.props.match.params.referrer}
{toHuman(this.state.query)}

+

{this.state.totalVisitors} visitors from {this.props.match.params.referrer}
{toHuman(this.state.query)}

{this.renderGoalText()}
Page urlPageviewsBounce ratePage urlPageviewsBounce rate
{ this.renderReferrerName(referrer.name) } - + appears in {referrer.tweets.length} tweets -
+
{ referrer.tweets.map(this.renderTweet) }
- - - {this.showBounceRate() && } + + + {this.showBounceRate() && } diff --git a/assets/js/dashboard/stats/modals/referrers.js b/assets/js/dashboard/stats/modals/referrers.js index 8632ac767..471c91d44 100644 --- a/assets/js/dashboard/stats/modals/referrers.js +++ b/assets/js/dashboard/stats/modals/referrers.js @@ -44,7 +44,7 @@ class ReferrersModal extends React.Component { return ( @@ -61,18 +61,16 @@ class ReferrersModal extends React.Component { } else if (this.state.referrers) { return ( -
-

Top Referrers

-
+

Top Referrers

-
+
ReferrerVisitorsBounce rateReferrerVisitorsBounce rate
- + { referrer.name } {numberFormatter(referrer.count)}
- - - {this.showBounceRate() && } + + + {this.showBounceRate() && } diff --git a/assets/js/dashboard/stats/more-link.js b/assets/js/dashboard/stats/more-link.js index bb2de95e7..172fcba7e 100644 --- a/assets/js/dashboard/stats/more-link.js +++ b/assets/js/dashboard/stats/more-link.js @@ -4,9 +4,9 @@ import { Link } from 'react-router-dom' export default function MoreLink({site, list, endpoint}) { if (list.length > 0) { return ( -
- - +
+ + MORE
diff --git a/assets/js/dashboard/stats/pages.js b/assets/js/dashboard/stats/pages.js index 532897a3f..ac62cbedd 100644 --- a/assets/js/dashboard/stats/pages.js +++ b/assets/js/dashboard/stats/pages.js @@ -35,8 +35,8 @@ export default class Pages extends React.Component { return (
- - {page.name} + + {page.name}
{numberFormatter(page.count)}
@@ -47,7 +47,7 @@ export default class Pages extends React.Component { if (this.state.pages.length > 0) { return ( -
+
Page url Pageviews
@@ -56,7 +56,7 @@ export default class Pages extends React.Component { ) } else { - return
No data yet
+ return
No data yet
} } @@ -64,7 +64,7 @@ export default class Pages extends React.Component { if (this.state.pages) { return ( -

Top Pages

+

Top Pages

{ this.renderList() }
diff --git a/assets/js/dashboard/stats/referrers.js b/assets/js/dashboard/stats/referrers.js index 9530fca04..45e8f3f2c 100644 --- a/assets/js/dashboard/stats/referrers.js +++ b/assets/js/dashboard/stats/referrers.js @@ -38,9 +38,9 @@ export default class Referrers extends React.Component { return (
- - - + + + { referrer.name }
@@ -53,7 +53,7 @@ export default class Referrers extends React.Component { if (this.state.referrers.length > 0) { return ( -
+
Referrer Visitors
@@ -62,7 +62,7 @@ export default class Referrers extends React.Component { ) } else { - return
No data yet
+ return
No data yet
} } @@ -70,7 +70,7 @@ export default class Referrers extends React.Component { if (this.state.referrers) { return ( -

Top Referrers

+

Top Referrers

{ this.renderList() }
diff --git a/assets/js/dashboard/stats/visitor-graph.js b/assets/js/dashboard/stats/visitor-graph.js index b292abf80..6ce9c8ab3 100644 --- a/assets/js/dashboard/stats/visitor-graph.js +++ b/assets/js/dashboard/stats/visitor-graph.js @@ -226,25 +226,25 @@ class LineGraph extends React.Component { const formattedComparison = numberFormatter(Math.abs(comparison)) if (comparison > 0) { - const color = name === 'Bounce rate' ? 'text-red-light' : 'text-green' + const color = name === 'Bounce rate' ? 'text-red-400' : 'text-green-500' return ↑ {formattedComparison}% } else if (comparison < 0) { - const color = name === 'Bounce rate' ? 'text-green' : 'text-red-light' + const color = name === 'Bounce rate' ? 'text-green-500' : 'text-red-400' return ↓ {formattedComparison}% } else if (comparison === 0) { - return 〰 N/A + return 〰 N/A } } renderTopStats() { const {graphData} = this.props return this.props.graphData.top_stats.map((stat, index) => { - let border = index > 0 ? 'lg:border-l border-grey-light' : '' + let border = index > 0 ? 'lg:border-l border-gray-300' : '' border = index % 2 === 0 ? border + ' border-r lg:border-r-0' : border return (
-
{stat.name}
+
{stat.name}
{ typeof(stat.count) == 'number' ? numberFormatter(stat.count) : stat.percentage + '%' } {this.renderComparison(stat.name, stat.change)} @@ -259,7 +259,7 @@ class LineGraph extends React.Component { return ( - + diff --git a/assets/package-lock.json b/assets/package-lock.json index 07a54cee9..255dcca8b 100644 --- a/assets/package-lock.json +++ b/assets/package-lock.json @@ -1059,6 +1059,22 @@ "to-fast-properties": "^2.0.0" } }, + "@fullhuman/postcss-purgecss": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/@fullhuman/postcss-purgecss/-/postcss-purgecss-2.1.0.tgz", + "integrity": "sha512-zmV+cK8pAo/suKMQk1fKzDdols5ltOy86Hk51qwkiJJt4olm3t1MaUrm4U4MlA9fiYeRpLqsNop2xNoEm8DV+w==", + "dev": true, + "requires": { + "postcss": "7.0.27", + "purgecss": "^2.1.0" + } + }, + "@types/color-name": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@types/color-name/-/color-name-1.1.1.tgz", + "integrity": "sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ==", + "dev": true + }, "@types/d3": { "version": "3.5.38", "resolved": "https://registry.npmjs.org/@types/d3/-/d3-3.5.38.tgz", @@ -1264,6 +1280,31 @@ "integrity": "sha512-/czfa8BwS88b9gWQVhc8eknunSA2DoJpJyTQkhheIf5E48u1N0R4q/YxxsAeqRrmK9TQ/uYfgLDfZo91UlANIA==", "dev": true }, + "acorn-node": { + "version": "1.8.2", + "resolved": "https://registry.npmjs.org/acorn-node/-/acorn-node-1.8.2.tgz", + "integrity": "sha512-8mt+fslDufLYntIoPAaIMUe/lrbrehIiwmR3t2k9LljIzoigEPF27eLk2hy8zSGzmR/ogr7zbRKINMo1u0yh5A==", + "dev": true, + "requires": { + "acorn": "^7.0.0", + "acorn-walk": "^7.0.0", + "xtend": "^4.0.2" + }, + "dependencies": { + "acorn": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-7.1.1.tgz", + "integrity": "sha512-add7dgA5ppRPxCFJoAGfMDi7PIBXq1RtGo7BhbLaxwrXPOmw8gq48Y9ozT01hUKy9byMjlR20EJhu5zlkErEkg==", + "dev": true + } + } + }, + "acorn-walk": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-7.1.1.tgz", + "integrity": "sha512-wdlPY2tm/9XBr7QkKlq0WQVgiuGTX6YWPyRyBviSoScBuLfTVQhvwg6wJ369GJ/1nPfTLMfnrFIfjqVg6d+jQQ==", + "dev": true + }, "ajv": { "version": "6.6.1", "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.6.1.tgz", @@ -1300,12 +1341,6 @@ "integrity": "sha512-hHUXGagefjN2iRrID63xckIvotOXOojhQKWIPUZ4mNUZ9nLZW+7FMNoE1lOkEhNWYsx/7ysGIuJYCiMAA9FnrA==", "dev": true }, - "ansi-regex": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", - "dev": true - }, "ansi-styles": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", @@ -1529,23 +1564,6 @@ } } }, - "babel-extract-comments": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/babel-extract-comments/-/babel-extract-comments-1.0.0.tgz", - "integrity": "sha512-qWWzi4TlddohA91bFwgt6zO/J0X+io7Qp184Fw0m2JYRSTZnJbFR8+07KmzudHCZgOiKRCrjhylwv9Xd8gfhVQ==", - "dev": true, - "requires": { - "babylon": "^6.18.0" - }, - "dependencies": { - "babylon": { - "version": "6.18.0", - "resolved": "https://registry.npmjs.org/babylon/-/babylon-6.18.0.tgz", - "integrity": "sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ==", - "dev": true - } - } - }, "babel-loader": { "version": "8.0.6", "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-8.0.6.tgz", @@ -1648,32 +1666,6 @@ "object.assign": "^4.1.0" } }, - "babel-plugin-syntax-object-rest-spread": { - "version": "6.13.0", - "resolved": "http://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz", - "integrity": "sha1-/WU28rzhODb/o6VFjEkDpZe7O/U=", - "dev": true - }, - "babel-plugin-transform-object-rest-spread": { - "version": "6.26.0", - "resolved": "https://registry.npmjs.org/babel-plugin-transform-object-rest-spread/-/babel-plugin-transform-object-rest-spread-6.26.0.tgz", - "integrity": "sha1-DzZpLVD+9rfi1LOsFHgTepY7ewY=", - "dev": true, - "requires": { - "babel-plugin-syntax-object-rest-spread": "^6.8.0", - "babel-runtime": "^6.26.0" - } - }, - "babel-runtime": { - "version": "6.26.0", - "resolved": "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz", - "integrity": "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=", - "dev": true, - "requires": { - "core-js": "^2.4.0", - "regenerator-runtime": "^0.11.0" - } - }, "balanced-match": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", @@ -2259,12 +2251,6 @@ "integrity": "sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ==", "dev": true }, - "comment-regex": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/comment-regex/-/comment-regex-1.0.1.tgz", - "integrity": "sha512-IWlN//Yfby92tOIje7J18HkNmWRR7JESA/BK8W7wqY/akITpU5B0JQWnbTjCfdChSrDNb0DrdA9jfAxiiBXyiQ==", - "dev": true - }, "commondir": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", @@ -2400,12 +2386,6 @@ } } }, - "core-js": { - "version": "2.5.7", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.5.7.tgz", - "integrity": "sha512-RszJCAxg/PP6uzXVXL6BsxSXx/B05oJAQ2vkJRjyjrEcNVycaqOmNb5OTxZPE3xa5gwZduqza6L9JOCenh/Ecw==", - "dev": true - }, "core-js-compat": { "version": "3.6.4", "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.6.4.tgz", @@ -2804,12 +2784,6 @@ "integrity": "sha512-a+EPoD+uZiNfh+5fxw2nO9QwFa6nJe2Or35fGY6Ipw1R3R4AGz1d1TEZrCegvw2YTmZ0jXirGYlzxxpYSHwpEg==", "dev": true }, - "css.escape": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/css.escape/-/css.escape-1.5.1.tgz", - "integrity": "sha1-QuJ9T6BK4y+TGktNQZH6nN3ul8s=", - "dev": true - }, "cssesc": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz", @@ -3220,6 +3194,17 @@ "integrity": "sha1-8NZtA2cqglyxtzvbP+YjEMjlUrc=", "dev": true }, + "detective": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/detective/-/detective-5.2.0.tgz", + "integrity": "sha512-6SsIx+nUUbuK0EthKjv0zrdnajCCXVYGmbYYiYjFVpzcjwEs/JMDZ8tPRG29J/HhN56t3GJp2cGSWDRjjot8Pg==", + "dev": true, + "requires": { + "acorn-node": "^1.6.1", + "defined": "^1.0.0", + "minimist": "^1.1.1" + } + }, "diffie-hellman": { "version": "5.0.3", "resolved": "http://registry.npmjs.org/diffie-hellman/-/diffie-hellman-5.0.3.tgz", @@ -3797,14 +3782,22 @@ } }, "fs-extra": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-4.0.3.tgz", - "integrity": "sha512-q6rbdDd1o2mAnQreO7YADIxf/Whx4AHBiRf6d+/cVT8h44ss+lHgxf1FemcqDnQt9X3ct4McHr+JMGlYSsK7Cg==", + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", + "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", "dev": true, "requires": { - "graceful-fs": "^4.1.2", + "graceful-fs": "^4.2.0", "jsonfile": "^4.0.0", "universalify": "^0.1.0" + }, + "dependencies": { + "graceful-fs": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.3.tgz", + "integrity": "sha512-a30VEBm4PEdx1dRB7MFK7BejejvCvBronbLjht+sHuGYj8PHs7M/5Z+rt5lw551vZ7yfTCj4Vuyy3mSJytDWRQ==", + "dev": true + } } }, "fs-write-stream-atomic": { @@ -4444,12 +4437,6 @@ "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" }, - "gather-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/gather-stream/-/gather-stream-1.0.0.tgz", - "integrity": "sha1-szmUr0V6gRVwDUEPMXczy+egkEs=", - "dev": true - }, "gensync": { "version": "1.0.0-beta.1", "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.1.tgz", @@ -4594,15 +4581,6 @@ "function-bind": "^1.1.1" } }, - "has-ansi": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", - "integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=", - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } - }, "has-flag": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", @@ -5171,12 +5149,6 @@ "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=", "dev": true }, - "js-base64": { - "version": "2.4.9", - "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-2.4.9.tgz", - "integrity": "sha512-xcinL3AuDJk7VSzsHgb9DvvIXayBbadtMZ4HFPx8rUszbW1MuNMlwYVC4zzCZ6e1sqZpnNS5ZFYOhXqA39T7LQ==", - "dev": true - }, "js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -5731,6 +5703,12 @@ "sort-keys": "^1.0.0" } }, + "normalize.css": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/normalize.css/-/normalize.css-8.0.1.tgz", + "integrity": "sha512-qizSNPO93t1YUuUhP22btGOo3chcvDFqFaj2TRybP0DMxkHOCTYwp3n34fel4a31ORXy4m1Xq0Gyqpb5m33qIg==", + "dev": true + }, "npm-run-path": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz", @@ -6084,24 +6062,6 @@ "sha.js": "^2.4.8" } }, - "perfectionist": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/perfectionist/-/perfectionist-2.4.0.tgz", - "integrity": "sha1-wUetNxThJkZ/F2QSnuct+GHUfqA=", - "dev": true, - "requires": { - "comment-regex": "^1.0.0", - "defined": "^1.0.0", - "minimist": "^1.2.0", - "postcss": "^5.0.8", - "postcss-scss": "^0.3.0", - "postcss-value-parser": "^3.3.0", - "read-file-stdin": "^0.2.0", - "string.prototype.repeat": "^0.2.0", - "vendors": "^1.0.0", - "write-file-stdout": "0.0.2" - } - }, "phoenix": { "version": "file:../deps/phoenix" }, @@ -6130,57 +6090,51 @@ "dev": true }, "postcss": { - "version": "5.2.18", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-5.2.18.tgz", - "integrity": "sha512-zrUjRRe1bpXKsX1qAJNJjqZViErVuyEkMTRrwu4ud4sbTtIBRmtaYDrHmcGgmrbsW3MHfmtIf+vJumgQn+PrXg==", + "version": "7.0.27", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-7.0.27.tgz", + "integrity": "sha512-WuQETPMcW9Uf1/22HWUWP9lgsIC+KEHg2kozMflKjbeUtw9ujvFX6QmIfozaErDkmLWS9WEnEdEe6Uo9/BNTdQ==", "dev": true, "requires": { - "chalk": "^1.1.3", - "js-base64": "^2.1.9", - "source-map": "^0.5.6", - "supports-color": "^3.2.3" + "chalk": "^2.4.2", + "source-map": "^0.6.1", + "supports-color": "^6.1.0" }, "dependencies": { - "ansi-styles": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", - "integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=", - "dev": true - }, "chalk": { - "version": "1.1.3", - "resolved": "http://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", - "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { - "ansi-styles": "^2.2.1", - "escape-string-regexp": "^1.0.2", - "has-ansi": "^2.0.0", - "strip-ansi": "^3.0.0", - "supports-color": "^2.0.0" + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" }, "dependencies": { "supports-color": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", - "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=", - "dev": true + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, + "requires": { + "has-flag": "^3.0.0" + } } } }, - "has-flag": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", - "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=", + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true }, "supports-color": { - "version": "3.2.3", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.2.3.tgz", - "integrity": "sha1-ZawFBLOVQXHYpklGsq48u4pfVPY=", + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz", + "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", "dev": true, "requires": { - "has-flag": "^1.0.0" + "has-flag": "^3.0.0" } } } @@ -6655,63 +6609,13 @@ } }, "postcss-js": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/postcss-js/-/postcss-js-2.0.2.tgz", - "integrity": "sha512-HxXLw1lrczsbVXxyC+t/VIfje9ZeZhkkXE8KpFa3MEKfp2FyHDv29JShYY9eLhYrhLyWWHNIuwkktTfLXu2otw==", + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/postcss-js/-/postcss-js-2.0.3.tgz", + "integrity": "sha512-zS59pAk3deu6dVHyrGqmC3oDXBdNdajk4k1RyxeVXCrcEDBUBHoIhE4QTsmhxgzXxsaqFDAkUZfmMa5f/N/79w==", "dev": true, "requires": { "camelcase-css": "^2.0.1", - "postcss": "^7.0.17" - }, - "dependencies": { - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - }, - "dependencies": { - "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } - } - }, - "postcss": { - "version": "7.0.17", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-7.0.17.tgz", - "integrity": "sha512-546ZowA+KZ3OasvQZHsbuEpysvwTZNGJv9EfyCQdsIDltPSWHAeTQ5fQy/Npi2ZDtLI3zs7Ps/p6wThErhm9fQ==", - "dev": true, - "requires": { - "chalk": "^2.4.2", - "source-map": "^0.6.1", - "supports-color": "^6.1.0" - } - }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - }, - "supports-color": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz", - "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } + "postcss": "^7.0.18" } }, "postcss-load-config": { @@ -7399,80 +7303,13 @@ } }, "postcss-nested": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/postcss-nested/-/postcss-nested-4.1.2.tgz", - "integrity": "sha512-9bQFr2TezohU3KRSu9f6sfecXmf/x6RXDedl8CHF6fyuyVW7UqgNMRdWMHZQWuFY6Xqs2NYk+Fj4Z4vSOf7PQg==", + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/postcss-nested/-/postcss-nested-4.2.1.tgz", + "integrity": "sha512-AMayXX8tS0HCp4O4lolp4ygj9wBn32DJWXvG6gCv+ZvJrEa00GUxJcJEEzMh87BIe6FrWdYkpR2cuyqHKrxmXw==", "dev": true, "requires": { - "postcss": "^7.0.14", - "postcss-selector-parser": "^5.0.0" - }, - "dependencies": { - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - }, - "dependencies": { - "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } - } - }, - "cssesc": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-2.0.0.tgz", - "integrity": "sha512-MsCAG1z9lPdoO/IUMLSBWBSVxVtJ1395VGIQ+Fc2gNdkQ1hNDnQdw3YhA71WJCBW1vdwA0cAnk/DnW6bqoEUYg==", - "dev": true - }, - "postcss": { - "version": "7.0.17", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-7.0.17.tgz", - "integrity": "sha512-546ZowA+KZ3OasvQZHsbuEpysvwTZNGJv9EfyCQdsIDltPSWHAeTQ5fQy/Npi2ZDtLI3zs7Ps/p6wThErhm9fQ==", - "dev": true, - "requires": { - "chalk": "^2.4.2", - "source-map": "^0.6.1", - "supports-color": "^6.1.0" - } - }, - "postcss-selector-parser": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-5.0.0.tgz", - "integrity": "sha512-w+zLE5Jhg6Liz8+rQOWEAwtwkyqpfnmsinXjXg6cY7YIONZZtgvE0v2O0uhQBs0peNomOJwWRKt6JBfTdTd3OQ==", - "dev": true, - "requires": { - "cssesc": "^2.0.0", - "indexes-of": "^1.0.1", - "uniq": "^1.0.1" - } - }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - }, - "supports-color": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz", - "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } + "postcss": "^7.0.21", + "postcss-selector-parser": "^6.0.2" } }, "postcss-normalize-charset": { @@ -8215,15 +8052,6 @@ } } }, - "postcss-scss": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/postcss-scss/-/postcss-scss-0.3.1.tgz", - "integrity": "sha1-ZcYQ2OKn7g5isYNbcbiHBzSBbks=", - "dev": true, - "requires": { - "postcss": "^5.2.4" - } - }, "postcss-selector-parser": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.0.2.tgz", @@ -8473,6 +8301,26 @@ "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", "dev": true }, + "purgecss": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/purgecss/-/purgecss-2.1.0.tgz", + "integrity": "sha512-QnXhowNjeWo9vNnGES2LVzDXdRR/8EvG/O03m4bYOWfAX0ShmG/Pmj7brVtVBy2eaaRAmNy23L+GBc4SpDFUeQ==", + "dev": true, + "requires": { + "commander": "^4.0.0", + "glob": "^7.0.0", + "postcss": "7.0.27", + "postcss-selector-parser": "^6.0.2" + }, + "dependencies": { + "commander": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz", + "integrity": "sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==", + "dev": true + } + } + }, "q": { "version": "1.5.1", "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", @@ -8596,15 +8444,6 @@ "tiny-warning": "^1.0.0" } }, - "read-file-stdin": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/read-file-stdin/-/read-file-stdin-0.2.1.tgz", - "integrity": "sha1-JezP86FTtoCa+ssj7hU4fbng7mE=", - "dev": true, - "requires": { - "gather-stream": "^1.0.0" - } - }, "readable-stream": { "version": "2.3.6", "resolved": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz", @@ -8630,6 +8469,16 @@ "readable-stream": "^2.0.2" } }, + "reduce-css-calc": { + "version": "2.1.7", + "resolved": "https://registry.npmjs.org/reduce-css-calc/-/reduce-css-calc-2.1.7.tgz", + "integrity": "sha512-fDnlZ+AybAS3C7Q9xDq5y8A2z+lT63zLbynew/lur/IR24OQF5x98tfNwf79mzEdfywZ0a2wpM860FhFfMxZlA==", + "dev": true, + "requires": { + "css-unit-converter": "^1.1.1", + "postcss-value-parser": "^3.3.0" + } + }, "regenerate": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.0.tgz", @@ -8645,12 +8494,6 @@ "regenerate": "^1.4.0" } }, - "regenerator-runtime": { - "version": "0.11.1", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz", - "integrity": "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==", - "dev": true - }, "regenerator-transform": { "version": "0.14.1", "resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.14.1.tgz", @@ -9366,12 +9209,6 @@ } } }, - "string.prototype.repeat": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/string.prototype.repeat/-/string.prototype.repeat-0.2.0.tgz", - "integrity": "sha1-q6Nt4I3O5qWjN9SbLqHaGyj8Ds8=", - "dev": true - }, "string_decoder": { "version": "1.1.1", "resolved": "http://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", @@ -9380,25 +9217,6 @@ "safe-buffer": "~5.1.0" } }, - "strip-ansi": { - "version": "3.0.1", - "resolved": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", - "dev": true, - "requires": { - "ansi-regex": "^2.0.0" - } - }, - "strip-comments": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/strip-comments/-/strip-comments-1.0.2.tgz", - "integrity": "sha512-kL97alc47hoyIQSV165tTt9rG5dn4w1dNnBhOQ3bOU1Nc1hel09jnXANaHJ7vzHLd4Ju8kseDGzlev96pghLFw==", - "dev": true, - "requires": { - "babel-extract-comments": "^1.0.0", - "babel-plugin-transform-object-rest-spread": "^6.26.0" - } - }, "strip-eof": { "version": "1.0.0", "resolved": "http://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", @@ -9507,128 +9325,78 @@ } }, "tailwindcss": { - "version": "0.7.4", - "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-0.7.4.tgz", - "integrity": "sha512-+GeQjHRJ2VmeLkrNwMCbPDfm2cc5P8eoc7n+DtZfI8oQdlo5eSHqsIlPEuZOtoqQlIALsd2jAggWrUUBFGP2ow==", + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-1.2.0.tgz", + "integrity": "sha512-CKvY0ytB3ze5qvynG7qv4XSpQtFNGPbu9pUn8qFdkqgD8Yo/vGss8mhzbqls44YCXTl4G62p3qVZBj45qrd6FQ==", "dev": true, "requires": { "autoprefixer": "^9.4.5", "bytes": "^3.0.0", - "chalk": "^2.4.1", - "css.escape": "^1.5.1", - "fs-extra": "^4.0.2", - "lodash": "^4.17.5", + "chalk": "^3.0.0", + "detective": "^5.2.0", + "fs-extra": "^8.0.0", + "lodash": "^4.17.15", "node-emoji": "^1.8.1", - "perfectionist": "^2.4.0", + "normalize.css": "^8.0.1", "postcss": "^7.0.11", "postcss-functions": "^3.0.0", "postcss-js": "^2.0.0", "postcss-nested": "^4.1.1", - "postcss-selector-parser": "^5.0.0", + "postcss-selector-parser": "^6.0.0", "pretty-hrtime": "^1.0.3", - "strip-comments": "^1.0.2" + "reduce-css-calc": "^2.1.6", + "resolve": "^1.14.2" }, "dependencies": { - "autoprefixer": { - "version": "9.6.1", - "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-9.6.1.tgz", - "integrity": "sha512-aVo5WxR3VyvyJxcJC3h4FKfwCQvQWb1tSI5VHNibddCVWrcD1NvlxEweg3TSgiPztMnWfjpy2FURKA2kvDE+Tw==", + "ansi-styles": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.2.1.tgz", + "integrity": "sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA==", "dev": true, "requires": { - "browserslist": "^4.6.3", - "caniuse-lite": "^1.0.30000980", - "chalk": "^2.4.2", - "normalize-range": "^0.1.2", - "num2fraction": "^1.2.2", - "postcss": "^7.0.17", - "postcss-value-parser": "^4.0.0" - }, - "dependencies": { - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - } - } + "@types/color-name": "^1.1.1", + "color-convert": "^2.0.1" } }, - "cssesc": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-2.0.0.tgz", - "integrity": "sha512-MsCAG1z9lPdoO/IUMLSBWBSVxVtJ1395VGIQ+Fc2gNdkQ1hNDnQdw3YhA71WJCBW1vdwA0cAnk/DnW6bqoEUYg==", - "dev": true - }, - "postcss": { - "version": "7.0.17", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-7.0.17.tgz", - "integrity": "sha512-546ZowA+KZ3OasvQZHsbuEpysvwTZNGJv9EfyCQdsIDltPSWHAeTQ5fQy/Npi2ZDtLI3zs7Ps/p6wThErhm9fQ==", + "chalk": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-3.0.0.tgz", + "integrity": "sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg==", "dev": true, "requires": { - "chalk": "^2.4.2", - "source-map": "^0.6.1", - "supports-color": "^6.1.0" - }, - "dependencies": { - "chalk": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", - "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.1", - "escape-string-regexp": "^1.0.5", - "supports-color": "^5.3.0" - }, - "dependencies": { - "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } - } - }, - "supports-color": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz", - "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" } }, - "postcss-selector-parser": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-5.0.0.tgz", - "integrity": "sha512-w+zLE5Jhg6Liz8+rQOWEAwtwkyqpfnmsinXjXg6cY7YIONZZtgvE0v2O0uhQBs0peNomOJwWRKt6JBfTdTd3OQ==", + "color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, "requires": { - "cssesc": "^2.0.0", - "indexes-of": "^1.0.1", - "uniq": "^1.0.1" + "color-name": "~1.1.4" } }, - "postcss-value-parser": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.0.2.tgz", - "integrity": "sha512-LmeoohTpp/K4UiyQCwuGWlONxXamGzCMtFxLq4W1nZVGIQLYvMCJx3yAF9qyyuFpflABI9yVdtJAqbihOsCsJQ==", + "color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true + }, + "supports-color": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", + "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", + "dev": true, + "requires": { + "has-flag": "^4.0.0" + } } } }, @@ -10417,12 +10185,6 @@ "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", "dev": true }, - "write-file-stdout": { - "version": "0.0.2", - "resolved": "https://registry.npmjs.org/write-file-stdout/-/write-file-stdout-0.0.2.tgz", - "integrity": "sha1-wlLXx8WxtAKJdjDjRTx7/mkNnKE=", - "dev": true - }, "xtend": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", diff --git a/assets/package.json b/assets/package.json index 19ee46e0b..b0c7d3fae 100644 --- a/assets/package.json +++ b/assets/package.json @@ -21,13 +21,14 @@ "@babel/core": "^7.8.3", "@babel/preset-env": "^7.8.3", "@babel/preset-react": "^7.8.3", + "@fullhuman/postcss-purgecss": "^2.1.0", "babel-loader": "^8.0.6", "copy-webpack-plugin": "^5.1.1", "css-loader": "^3.4.2", "mini-css-extract-plugin": "^0.8.2", "optimize-css-assets-webpack-plugin": "^5.0.3", "postcss-loader": "^3.0.0", - "tailwindcss": "^0.7.4", + "tailwindcss": "^1.2.0", "uglifyjs-webpack-plugin": "^2.2.0", "webpack": "4.39.2", "webpack-cli": "^3.3.10" diff --git a/assets/postcss.config.js b/assets/postcss.config.js index cebc0b9a6..2f347c00c 100644 --- a/assets/postcss.config.js +++ b/assets/postcss.config.js @@ -1,8 +1,18 @@ -var tailwindcss = require('tailwindcss'); +const purgecss = require('@fullhuman/postcss-purgecss')({ + content: [ + './js/**/*.js', + '../lib/plausible_web/templates/**/*.html.eex', + ], + + defaultExtractor: content => content.match(/[\w-/:]+(? ({ + auto: 'auto', + '44': '11rem', + ...theme('spacing'), + ...negative(theme('spacing')), + }), + width: theme => ({ + auto: 'auto', + ...theme('spacing'), + '1/2': '50%', + '1/3': '33.333333%', + '31percent': '31%', + '2/3': '66.666667%', + '1/4': '25%', + '2/4': '50%', + '3/4': '75%', + '1/5': '20%', + '2/5': '40%', + '3/5': '60%', + '4/5': '80%', + '1/6': '16.666667%', + '2/6': '33.333333%', + '3/6': '50%', + '4/6': '66.666667%', + '5/6': '83.333333%', + '1/12': '8.333333%', + '2/12': '16.666667%', + '3/12': '25%', + '4/12': '33.333333%', + '5/12': '41.666667%', + '6/12': '50%', + '7/12': '58.333333%', + '8/12': '66.666667%', + '9/12': '75%', + '10/12': '83.333333%', + '11/12': '91.666667%', + full: '100%', + screen: '100vw', + }), + }, + variants: { + textColor: ['responsive', 'hover', 'focus', 'group-hover'] + }, + corePlugins: {}, + plugins: [], +} diff --git a/assets/tailwind.js b/assets/tailwind.js deleted file mode 100644 index 63073a3a5..000000000 --- a/assets/tailwind.js +++ /dev/null @@ -1,963 +0,0 @@ -/* - -Tailwind - The Utility-First CSS Framework - -A project by Adam Wathan (@adamwathan), Jonathan Reinink (@reinink), -David Hemphill (@davidhemphill) and Steve Schoger (@steveschoger). - -Welcome to the Tailwind config file. This is where you can customize -Tailwind specifically for your project. Don't be intimidated by the -length of this file. It's really just a big JavaScript object and -we've done our very best to explain each section. - -View the full documentation at https://tailwindcss.com. - - -|------------------------------------------------------------------------------- -| The default config -|------------------------------------------------------------------------------- -| -| This variable contains the default Tailwind config. You don't have -| to use it, but it can sometimes be helpful to have available. For -| example, you may choose to merge your custom configuration -| values with some of the Tailwind defaults. -| -*/ - -let defaultConfig = require('tailwindcss/defaultConfig')() - - -/* -|------------------------------------------------------------------------------- -| Colors https://tailwindcss.com/docs/colors -|------------------------------------------------------------------------------- -| -| Here you can specify the colors used in your project. To get you started, -| we've provided a generous palette of great looking colors that are perfect -| for prototyping, but don't hesitate to change them for your project. You -| own these colors, nothing will break if you change everything about them. -| -| We've used literal color names ("red", "blue", etc.) for the default -| palette, but if you'd rather use functional names like "primary" and -| "secondary", or even a numeric scale like "100" and "200", go for it. -| -*/ - -let colors = { - 'transparent': 'transparent', - - 'black': '#22292f', - 'grey-darkest': '#3d4852', - 'grey-darker': '#606f7b', - 'grey-dark': '#8795a1', - 'grey': '#b8c2cc', - 'grey-light': '#dae1e7', - 'grey-lighter': '#f1f5f8', - 'grey-lightest': '#f8fafc', - 'white': '#ffffff', - - 'red-darkest': '#3b0d0c', - 'red-darker': '#621b18', - 'red-dark': '#ff4457', // USE - 'red': '#ff6978', // USE - 'red-light': '#ef5753', - 'red-lighter': '#f9acaa', - 'red-lightest': '#fcebea', - - 'orange-darkest': '#462a16', - 'orange-darker': '#613b1f', - 'orange-dark': '#de751f', - 'orange': '#f6993f', - 'orange-light': '#faad63', - 'orange-lighter': '#fcd9b6', - 'orange-lightest': '#fff5eb', - - 'yellow-darkest': '#453411', - 'yellow-darker': '#684f1d', - 'yellow-dark': '#f2d024', - 'yellow': '#ffed4a', - 'yellow-light': '#fff382', - 'yellow-lighter': '#fff9c2', - 'yellow-lightest': '#fcfbeb', - - 'green-darkest': '#0f2f21', - 'green-darker': '#1a4731', - 'green-dark': '#1f9d55', - 'green': '#38C172', // USE - 'green-light': '#51d88a', - 'green-lighter': '#a2f5bf', - 'green-lightest': '#e3fcec', - - 'teal-darkest': '#0d3331', - 'teal-darker': '#20504f', - 'teal-dark': '#38a89d', - 'teal': '#4dc0b5', - 'teal-light': '#64d5ca', - 'teal-lighter': '#a0f0ed', - 'teal-lightest': '#e8fffe', - - 'blue-darkest': '#12283a', - 'blue-darker': '#1c3d5a', - 'blue-dark': '#2779bd', - 'blue': '#3490dc', - 'blue-light': '#6cb2eb', - 'blue-lighter': '#bcdefa', - 'blue-lightest': '#eff8ff', - - 'indigo-darkest': '#191e38', - 'indigo-darker': '#2f365f', - 'indigo-dark': '#5661b3', - 'indigo': '#6574cd', - 'indigo-light': '#7886d7', - 'indigo-lighter': '#b2b7ff', - 'indigo-lightest': '#e6e8ff', - - 'purple-darkest': '#21183c', - 'purple-darker': '#382b5f', - 'purple-dark': '#794acf', - 'purple': '#9561e2', - 'purple-light': '#a779e9', - 'purple-lighter': '#d6bbfc', - 'purple-lightest': '#f3ebff', - - 'pink-darkest': '#451225', - 'pink-darker': '#6f213f', - 'pink-dark': '#eb5286', - 'pink': '#f66d9b', - 'pink-light': '#fa7ea8', - 'pink-lighter': '#ffbbca', - 'pink-lightest': '#ffebef', -} - -module.exports = { - - /* - |----------------------------------------------------------------------------- - | Colors https://tailwindcss.com/docs/colors - |----------------------------------------------------------------------------- - | - | The color palette defined above is also assigned to the "colors" key of - | your Tailwind config. This makes it easy to access them in your CSS - | using Tailwind's config helper. For example: - | - | .error { color: config('colors.red') } - | - */ - - colors: colors, - - - /* - |----------------------------------------------------------------------------- - | Screens https://tailwindcss.com/docs/responsive-design - |----------------------------------------------------------------------------- - | - | Screens in Tailwind are translated to CSS media queries. They define the - | responsive breakpoints for your project. By default Tailwind takes a - | "mobile first" approach, where each screen size represents a minimum - | viewport width. Feel free to have as few or as many screens as you - | want, naming them in whatever way you'd prefer for your project. - | - | Tailwind also allows for more complex screen definitions, which can be - | useful in certain situations. Be sure to see the full responsive - | documentation for a complete list of options. - | - | Class name: .{screen}:{utility} - | - */ - - screens: { - 'sm': '576px', - 'md': '768px', - 'lg': '992px', - 'xl': '1200px', - }, - - - /* - |----------------------------------------------------------------------------- - | Fonts https://tailwindcss.com/docs/fonts - |----------------------------------------------------------------------------- - | - | Here is where you define your project's font stack, or font families. - | Keep in mind that Tailwind doesn't actually load any fonts for you. - | If you're using custom fonts you'll need to import them prior to - | defining them here. - | - | By default we provide a native font stack that works remarkably well on - | any device or OS you're using, since it just uses the default fonts - | provided by the platform. - | - | Class name: .font-{name} - | - */ - - fonts: { - 'sans': [ - 'system-ui', - 'BlinkMacSystemFont', - '-apple-system', - 'Segoe UI', - 'Roboto', - 'Oxygen', - 'Ubuntu', - 'Cantarell', - 'Fira Sans', - 'Droid Sans', - 'Helvetica Neue', - 'sans-serif', - ], - 'serif': [ - 'Constantia', - 'Lucida Bright', - 'Lucidabright', - 'Lucida Serif', - 'Lucida', - 'DejaVu Serif', - 'Bitstream Vera Serif', - 'Liberation Serif', - 'Georgia', - 'serif', - ], - 'mono': [ - 'Menlo', - 'Monaco', - 'Consolas', - 'Liberation Mono', - 'Courier New', - 'monospace', - ], - }, - - - /* - |----------------------------------------------------------------------------- - | Text sizes https://tailwindcss.com/docs/text-sizing - |----------------------------------------------------------------------------- - | - | Here is where you define your text sizes. Name these in whatever way - | makes the most sense to you. We use size names by default, but - | you're welcome to use a numeric scale or even something else - | entirely. - | - | By default Tailwind uses the "rem" unit type for most measurements. - | This allows you to set a root font size which all other sizes are - | then based on. That said, you are free to use whatever units you - | prefer, be it rems, ems, pixels or other. - | - | Class name: .text-{size} - | - */ - - textSizes: { - 'xs': '.75rem', // 12px - 'sm': '.875rem', // 14px - 'base': '1rem', // 16px - 'lg': '1.125rem', // 18px - 'xl': '1.25rem', // 20px - '2xl': '1.5rem', // 24px - '3xl': '1.875rem', // 30px - '4xl': '2.25rem', // 36px - '5xl': '3rem', // 48px - }, - - - /* - |----------------------------------------------------------------------------- - | Font weights https://tailwindcss.com/docs/font-weight - |----------------------------------------------------------------------------- - | - | Here is where you define your font weights. We've provided a list of - | common font weight names with their respective numeric scale values - | to get you started. It's unlikely that your project will require - | all of these, so we recommend removing those you don't need. - | - | Class name: .font-{weight} - | - */ - - fontWeights: { - 'hairline': 100, - 'thin': 200, - 'light': 300, - 'normal': 400, - 'medium': 500, - 'semibold': 600, - 'bold': 700, - 'extrabold': 800, - 'black': 900, - }, - - - /* - |----------------------------------------------------------------------------- - | Leading (line height) https://tailwindcss.com/docs/line-height - |----------------------------------------------------------------------------- - | - | Here is where you define your line height values, or as we call - | them in Tailwind, leadings. - | - | Class name: .leading-{size} - | - */ - - leading: { - 'none': 1, - 'tight': 1.25, - 'normal': 1.5, - 'loose': 2, - }, - - - /* - |----------------------------------------------------------------------------- - | Tracking (letter spacing) https://tailwindcss.com/docs/letter-spacing - |----------------------------------------------------------------------------- - | - | Here is where you define your letter spacing values, or as we call - | them in Tailwind, tracking. - | - | Class name: .tracking-{size} - | - */ - - tracking: { - 'tight': '-0.05em', - 'normal': '0', - 'wide': '0.05em', - }, - - - /* - |----------------------------------------------------------------------------- - | Text colors https://tailwindcss.com/docs/text-color - |----------------------------------------------------------------------------- - | - | Here is where you define your text colors. By default these use the - | color palette we defined above, however you're welcome to set these - | independently if that makes sense for your project. - | - | Class name: .text-{color} - | - */ - - textColors: colors, - - - /* - |----------------------------------------------------------------------------- - | Background colors https://tailwindcss.com/docs/background-color - |----------------------------------------------------------------------------- - | - | Here is where you define your background colors. By default these use - | the color palette we defined above, however you're welcome to set - | these independently if that makes sense for your project. - | - | Class name: .bg-{color} - | - */ - - backgroundColors: colors, - - - /* - |----------------------------------------------------------------------------- - | Background sizes https://tailwindcss.com/docs/background-size - |----------------------------------------------------------------------------- - | - | Here is where you define your background sizes. We provide some common - | values that are useful in most projects, but feel free to add other sizes - | that are specific to your project here as well. - | - | Class name: .bg-{size} - | - */ - - backgroundSize: { - 'auto': 'auto', - 'cover': 'cover', - 'contain': 'contain', - }, - - - /* - |----------------------------------------------------------------------------- - | Border widths https://tailwindcss.com/docs/border-width - |----------------------------------------------------------------------------- - | - | Here is where you define your border widths. Take note that border - | widths require a special "default" value set as well. This is the - | width that will be used when you do not specify a border width. - | - | Class name: .border{-side?}{-width?} - | - */ - - borderWidths: { - default: '1px', - '0': '0', - '2': '2px', - '4': '4px', - '8': '8px', - }, - - - /* - |----------------------------------------------------------------------------- - | Border colors https://tailwindcss.com/docs/border-color - |----------------------------------------------------------------------------- - | - | Here is where you define your border colors. By default these use the - | color palette we defined above, however you're welcome to set these - | independently if that makes sense for your project. - | - | Take note that border colors require a special "default" value set - | as well. This is the color that will be used when you do not - | specify a border color. - | - | Class name: .border-{color} - | - */ - - borderColors: global.Object.assign({ default: colors['grey-light'] }, colors), - - - /* - |----------------------------------------------------------------------------- - | Border radius https://tailwindcss.com/docs/border-radius - |----------------------------------------------------------------------------- - | - | Here is where you define your border radius values. If a `default` radius - | is provided, it will be made available as the non-suffixed `.rounded` - | utility. - | - | If your scale includes a `0` value to reset already rounded corners, it's - | a good idea to put it first so other values are able to override it. - | - | Class name: .rounded{-side?}{-size?} - | - */ - - borderRadius: { - 'none': '0', - 'sm': '.125rem', - default: '.25rem', - 'lg': '.5rem', - 'full': '9999px', - }, - - - /* - |----------------------------------------------------------------------------- - | Width https://tailwindcss.com/docs/width - |----------------------------------------------------------------------------- - | - | Here is where you define your width utility sizes. These can be - | percentage based, pixels, rems, or any other units. By default - | we provide a sensible rem based numeric scale, a percentage - | based fraction scale, plus some other common use-cases. You - | can, of course, modify these values as needed. - | - | - | It's also worth mentioning that Tailwind automatically escapes - | invalid CSS class name characters, which allows you to have - | awesome classes like .w-2/3. - | - | Class name: .w-{size} - | - */ - - width: { - 'auto': 'auto', - 'px': '1px', - '1': '0.25rem', - '2': '0.5rem', - '3': '0.75rem', - '4': '1rem', - '5': '1.25rem', - '6': '1.5rem', - '8': '2rem', - '10': '2.5rem', - '12': '3rem', - '16': '4rem', - '24': '6rem', - '32': '8rem', - '48': '12rem', - '52': '13rem', - '60': '15rem', - '64': '16rem', - '1/2': '50%', - '31percent': '31%', - '1/3': '33.33333%', - '2/3': '66.66667%', - '1/4': '25%', - '3/4': '75%', - '1/5': '20%', - '2/5': '40%', - '3/5': '60%', - '4/5': '80%', - '1/6': '16.66667%', - '5/6': '83.33333%', - 'full': '100%', - 'screen': '100vw', - }, - - - /* - |----------------------------------------------------------------------------- - | Height https://tailwindcss.com/docs/height - |----------------------------------------------------------------------------- - | - | Here is where you define your height utility sizes. These can be - | percentage based, pixels, rems, or any other units. By default - | we provide a sensible rem based numeric scale plus some other - | common use-cases. You can, of course, modify these values as - | needed. - | - | Class name: .h-{size} - | - */ - - height: { - 'auto': 'auto', - 'px': '1px', - '1': '0.25rem', - '2': '0.5rem', - '3': '0.75rem', - '4': '1rem', - '5': '1.25rem', - '6': '1.5rem', - '8': '2rem', - '10': '2.5rem', - '12': '3rem', - '16': '4rem', - '24': '6rem', - '32': '8rem', - '48': '12rem', - '64': '16rem', - '72': '18rem', - 'full': '100%', - 'screen': '100vh', - }, - - - /* - |----------------------------------------------------------------------------- - | Minimum width https://tailwindcss.com/docs/min-width - |----------------------------------------------------------------------------- - | - | Here is where you define your minimum width utility sizes. These can - | be percentage based, pixels, rems, or any other units. We provide a - | couple common use-cases by default. You can, of course, modify - | these values as needed. - | - | Class name: .min-w-{size} - | - */ - - minWidth: { - '0': '0', - 'full': '100%', - }, - - - /* - |----------------------------------------------------------------------------- - | Minimum height https://tailwindcss.com/docs/min-height - |----------------------------------------------------------------------------- - | - | Here is where you define your minimum height utility sizes. These can - | be percentage based, pixels, rems, or any other units. We provide a - | few common use-cases by default. You can, of course, modify these - | values as needed. - | - | Class name: .min-h-{size} - | - */ - - minHeight: { - '0': '0', - 'full': '100%', - 'screen': '100vh', - }, - - - /* - |----------------------------------------------------------------------------- - | Maximum width https://tailwindcss.com/docs/max-width - |----------------------------------------------------------------------------- - | - | Here is where you define your maximum width utility sizes. These can - | be percentage based, pixels, rems, or any other units. By default - | we provide a sensible rem based scale and a "full width" size, - | which is basically a reset utility. You can, of course, - | modify these values as needed. - | - | Class name: .max-w-{size} - | - */ - - maxWidth: { - 'xs': '20rem', - 'sm': '30rem', - 'md': '40rem', - 'lg': '50rem', - 'xl': '60rem', - '2xl': '70rem', - '3xl': '80rem', - '4xl': '90rem', - '5xl': '100rem', - 'full': '100%', - }, - - - /* - |----------------------------------------------------------------------------- - | Maximum height https://tailwindcss.com/docs/max-height - |----------------------------------------------------------------------------- - | - | Here is where you define your maximum height utility sizes. These can - | be percentage based, pixels, rems, or any other units. We provide a - | couple common use-cases by default. You can, of course, modify - | these values as needed. - | - | Class name: .max-h-{size} - | - */ - - maxHeight: { - 'full': '100%', - 'screen': '100vh', - }, - - - /* - |----------------------------------------------------------------------------- - | Padding https://tailwindcss.com/docs/padding - |----------------------------------------------------------------------------- - | - | Here is where you define your padding utility sizes. These can be - | percentage based, pixels, rems, or any other units. By default we - | provide a sensible rem based numeric scale plus a couple other - | common use-cases like "1px". You can, of course, modify these - | values as needed. - | - | Class name: .p{side?}-{size} - | - */ - - padding: { - 'px': '1px', - '0': '0', - '1': '0.25rem', - '2': '0.5rem', - '3': '0.75rem', - '4': '1rem', - '5': '1.25rem', - '6': '1.5rem', - '8': '2rem', - '10': '2.5rem', - '12': '3rem', - '16': '4rem', - '20': '5rem', - '24': '6rem', - '32': '8rem', - '48': '12rem', - }, - - - /* - |----------------------------------------------------------------------------- - | Margin https://tailwindcss.com/docs/margin - |----------------------------------------------------------------------------- - | - | Here is where you define your margin utility sizes. These can be - | percentage based, pixels, rems, or any other units. By default we - | provide a sensible rem based numeric scale plus a couple other - | common use-cases like "1px". You can, of course, modify these - | values as needed. - | - | Class name: .m{side?}-{size} - | - */ - - margin: { - 'auto': 'auto', - 'px': '1px', - '0': '0', - '1': '0.25rem', - '2': '0.5rem', - '3': '0.75rem', - '4': '1rem', - '5': '1.25rem', - '6': '1.5rem', - '8': '2rem', - '10': '2.5rem', - '12': '3rem', - '16': '4rem', - '20': '5rem', - '24': '6rem', - '32': '8rem', - '44': '11rem', - '48': '12rem', - }, - - - /* - |----------------------------------------------------------------------------- - | Negative margin https://tailwindcss.com/docs/negative-margin - |----------------------------------------------------------------------------- - | - | Here is where you define your negative margin utility sizes. These can - | be percentage based, pixels, rems, or any other units. By default we - | provide matching values to the padding scale since these utilities - | generally get used together. You can, of course, modify these - | values as needed. - | - | Class name: .-m{side?}-{size} - | - */ - - negativeMargin: { - 'px': '1px', - '0': '0', - '1': '0.25rem', - '2': '0.5rem', - '3': '0.75rem', - '4': '1rem', - '5': '1.25rem', - '6': '1.5rem', - '8': '2rem', - '10': '2.5rem', - '12': '3rem', - '16': '4rem', - '20': '5rem', - '24': '6rem', - '32': '8rem', - }, - - - /* - |----------------------------------------------------------------------------- - | Shadows https://tailwindcss.com/docs/shadows - |----------------------------------------------------------------------------- - | - | Here is where you define your shadow utilities. As you can see from - | the defaults we provide, it's possible to apply multiple shadows - | per utility using comma separation. - | - | If a `default` shadow is provided, it will be made available as the non- - | suffixed `.shadow` utility. - | - | Class name: .shadow-{size?} - | - */ - - shadows: { - default: '0 2px 4px 0 rgba(0,0,0,0.10)', - 'md': '0 4px 8px 0 rgba(0,0,0,0.12), 0 2px 4px 0 rgba(0,0,0,0.08)', - 'lg': '0 15px 30px 0 rgba(0,0,0,0.11), 0 5px 15px 0 rgba(0,0,0,0.08)', - 'xl': '8px 14px 38px rgba(39,44,49,.06),1px 3px 8px rgba(39,44,49,.03);', - 'inner': 'inset 0 2px 4px 0 rgba(0,0,0,0.06)', - 'outline': '0 0 0 3px rgba(52,144,220,0.5)', - 'none': 'none', - }, - - - /* - |----------------------------------------------------------------------------- - | Z-index https://tailwindcss.com/docs/z-index - |----------------------------------------------------------------------------- - | - | Here is where you define your z-index utility values. By default we - | provide a sensible numeric scale. You can, of course, modify these - | values as needed. - | - | Class name: .z-{index} - | - */ - - zIndex: { - 'auto': 'auto', - '0': 0, - '10': 10, - '20': 20, - '30': 30, - '40': 40, - '50': 50, - }, - - - /* - |----------------------------------------------------------------------------- - | Opacity https://tailwindcss.com/docs/opacity - |----------------------------------------------------------------------------- - | - | Here is where you define your opacity utility values. By default we - | provide a sensible numeric scale. You can, of course, modify these - | values as needed. - | - | Class name: .opacity-{name} - | - */ - - opacity: { - '0': '0', - '25': '.25', - '50': '.5', - '75': '.75', - '100': '1', - }, - - - /* - |----------------------------------------------------------------------------- - | SVG fill https://tailwindcss.com/docs/svg - |----------------------------------------------------------------------------- - | - | Here is where you define your SVG fill colors. By default we just provide - | `fill-current` which sets the fill to the current text color. This lets you - | specify a fill color using existing text color utilities and helps keep the - | generated CSS file size down. - | - | Class name: .fill-{name} - | - */ - - svgFill: { - 'current': 'currentColor', - }, - - - /* - |----------------------------------------------------------------------------- - | SVG stroke https://tailwindcss.com/docs/svg - |----------------------------------------------------------------------------- - | - | Here is where you define your SVG stroke colors. By default we just provide - | `stroke-current` which sets the stroke to the current text color. This lets - | you specify a stroke color using existing text color utilities and helps - | keep the generated CSS file size down. - | - | Class name: .stroke-{name} - | - */ - - svgStroke: { - 'current': 'currentColor', - }, - - - /* - |----------------------------------------------------------------------------- - | Modules https://tailwindcss.com/docs/configuration#modules - |----------------------------------------------------------------------------- - | - | Here is where you control which modules are generated and what variants are - | generated for each of those modules. - | - | Currently supported variants: - | - responsive - | - hover - | - focus - | - focus-within - | - active - | - group-hover - | - | To disable a module completely, use `false` instead of an array. - | - */ - - modules: { - appearance: ['responsive'], - backgroundAttachment: ['responsive'], - backgroundColors: ['responsive', 'hover', 'focus'], - backgroundPosition: ['responsive'], - backgroundRepeat: ['responsive'], - backgroundSize: ['responsive'], - borderCollapse: [], - borderColors: ['responsive', 'hover', 'focus'], - borderRadius: ['responsive'], - borderStyle: ['responsive'], - borderWidths: ['responsive'], - cursor: ['responsive'], - display: ['responsive'], - flexbox: ['responsive'], - float: ['responsive'], - fonts: ['responsive'], - fontWeights: ['responsive', 'hover', 'focus'], - height: ['responsive'], - leading: ['responsive'], - lists: ['responsive'], - margin: ['responsive'], - maxHeight: ['responsive'], - maxWidth: ['responsive'], - minHeight: ['responsive'], - minWidth: ['responsive'], - negativeMargin: ['responsive'], - objectFit: false, - objectPosition: false, - opacity: ['responsive', 'group-hover'], - outline: ['focus'], - overflow: ['responsive'], - padding: ['responsive'], - pointerEvents: ['responsive'], - position: ['responsive'], - resize: ['responsive'], - shadows: ['responsive', 'hover', 'focus'], - svgFill: [], - svgStroke: [], - tableLayout: ['responsive'], - textAlign: ['responsive'], - textColors: ['responsive', 'hover', 'focus', 'group-hover'], - textSizes: ['responsive'], - textStyle: ['responsive', 'hover', 'focus'], - tracking: ['responsive'], - userSelect: ['responsive'], - verticalAlign: ['responsive'], - visibility: ['responsive'], - whitespace: ['responsive'], - width: ['responsive'], - zIndex: ['responsive'], - }, - - - /* - |----------------------------------------------------------------------------- - | Plugins https://tailwindcss.com/docs/plugins - |----------------------------------------------------------------------------- - | - | Here is where you can register any plugins you'd like to use in your - | project. Tailwind's built-in `container` plugin is enabled by default to - | give you a Bootstrap-style responsive container component out of the box. - | - | Be sure to view the complete plugin documentation to learn more about how - | the plugin system works. - | - */ - - plugins: [ - require('tailwindcss/plugins/container')({ - center: true, - padding: '1rem', - }), - ], - - - /* - |----------------------------------------------------------------------------- - | Advanced Options https://tailwindcss.com/docs/configuration#options - |----------------------------------------------------------------------------- - | - | Here is where you can tweak advanced configuration options. We recommend - | leaving these options alone unless you absolutely need to change them. - | - */ - - options: { - prefix: '', - important: false, - separator: ':', - }, - -} diff --git a/lib/plausible/auth/user.ex b/lib/plausible/auth/user.ex index c14294fd1..455c2ce6d 100644 --- a/lib/plausible/auth/user.ex +++ b/lib/plausible/auth/user.ex @@ -36,7 +36,7 @@ defmodule Plausible.Auth.User do user |> cast(%{password: password}, [:password]) |> validate_required(:password) - |> validate_length(:password, min: 6) + |> validate_length(:password, min: 6, message: "has to be at least 6 characters") |> cast(%{password_hash: hash}, [:password_hash]) end end diff --git a/lib/plausible_web/templates/auth/login_form.html.eex b/lib/plausible_web/templates/auth/login_form.html.eex index d7fdf526e..ed4c3859e 100644 --- a/lib/plausible_web/templates/auth/login_form.html.eex +++ b/lib/plausible_web/templates/auth/login_form.html.eex @@ -1,22 +1,22 @@ -<%= form_for @conn, "/login", [class: "w-full max-w-sm mx-auto bg-white shadow-md rounded px-8 py-6 mt-8"], fn f -> %> -

<%= get_flash(@conn, :login_title) || "Enter your email and password" %>

+<%= form_for @conn, "/login", [class: "w-full max-w-md mx-auto bg-white shadow-md rounded px-8 py-6 mt-8"], fn f -> %> +

<%= get_flash(@conn, :login_title) || "Enter your email and password" %>

<%= if get_flash(@conn, :login_instructions) do %> -

<%= get_flash(@conn, :login_instructions) %>

+

<%= get_flash(@conn, :login_instructions) %>

<% end %> <%= if @conn.assigns[:error] do %> -
<%= @conn.assigns[:error] %>
+
<%= @conn.assigns[:error] %>
<% end %>
- <%= label f, :email, class: "block text-grey-darker text-sm font-bold mb-2" %> - <%= email_input f, :email, class: "bg-grey-lighter appearance-none border border-transparent rounded w-full p-2 text-grey-darker leading-normal appearance-none focus:outline-none focus:bg-white focus:border-grey-light", placeholder: "user@example.com" %> + <%= label f, :email, class: "block text-gray-700 text-sm font-bold mb-2" %> + <%= email_input f, :email, class: "bg-gray-200 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300", placeholder: "user@example.com" %>
- <%= label f, :password, class: "block text-grey-darker text-sm font-bold mb-2" %> - <%= password_input f, :password, class: "transition bg-grey-lighter appearance-none border border-transparent rounded w-full p-2 text-grey-darker leading-normal appearance-none focus:outline-none focus:bg-white focus:border-grey-light" %> -

Forgot password? Click here to reset it.

+ <%= label f, :password, class: "block text-gray-700 text-sm font-bold mb-2" %> + <%= password_input f, :password, class: "transition bg-gray-200 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300" %> +

Forgot password? Click here to reset it.

<%= submit "Login →", class: "button mt-4 w-full" %> -

+

Don't have an account? <%= link("Register", to: "/register") %> instead.

<% end %> diff --git a/lib/plausible_web/templates/auth/password_form.html.eex b/lib/plausible_web/templates/auth/password_form.html.eex index c59575e94..d819e091c 100644 --- a/lib/plausible_web/templates/auth/password_form.html.eex +++ b/lib/plausible_web/templates/auth/password_form.html.eex @@ -1,14 +1,14 @@ -<%= form_for @conn, "/password", [class: "bg-white max-w-sm w-full mx-auto shadow-md rounded px-8 py-6 mt-8"], fn f -> %> -

Set your password

-

Min 6 characters

+<%= form_for @conn, "/password", [class: "bg-white max-w-md w-full mx-auto shadow-md rounded px-8 py-6 mt-8"], fn f -> %> +

Set your password

- <%= password_input f, :password, class: "transition bg-grey-lighter appearance-none border border-transparent rounded w-full p-2 text-grey-darker leading-normal appearance-none focus:outline-none focus:bg-white focus:border-grey-light" %> +

Min 6 characters

+ <%= password_input f, :password, class: "transition bg-gray-200 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300" %> <%= if @conn.assigns[:changeset] do %> <%= error_tag @changeset, :password %> <% end %>
<%= submit "Set password →", class: "button mt-4 w-full" %> -

+

Don't have an account? <%= link("Register", to: "/register") %> instead.

<% end %> diff --git a/lib/plausible_web/templates/auth/password_reset_form.html.eex b/lib/plausible_web/templates/auth/password_reset_form.html.eex index 939936730..c25aa1cfd 100644 --- a/lib/plausible_web/templates/auth/password_reset_form.html.eex +++ b/lib/plausible_web/templates/auth/password_reset_form.html.eex @@ -1,15 +1,15 @@ -<%= form_for @conn, "/password/reset", [class: "bg-white max-w-sm w-full mx-auto shadow-md rounded px-8 py-6 mt-8"], fn f -> %> -

Reset your password

-

Min 6 characters

-
- <%= password_input f, :password, class: "transition bg-grey-lighter appearance-none border border-transparent rounded w-full p-2 text-grey-darker leading-normal appearance-none focus:outline-none focus:bg-white focus:border-grey-light" %> +<%= form_for @conn, "/password/reset", [class: "bg-white max-w-md w-full mx-auto shadow-md rounded px-8 py-6 mt-8"], fn f -> %> +

Reset your password

+
+

Min 6 characters

+ <%= password_input f, :password, class: "transition bg-gray-200 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300" %> <%= if @conn.assigns[:changeset] do %> <%= error_tag @changeset, :password %> <% end %>
<%= hidden_input f, :token, value: @token %> <%= submit "Set password →", class: "button mt-4 w-full" %> -

+

Don't have an account? <%= link("Register", to: "/register") %> instead.

<% end %> diff --git a/lib/plausible_web/templates/auth/password_reset_request_form.html.eex b/lib/plausible_web/templates/auth/password_reset_request_form.html.eex index b491fbb28..230b14468 100644 --- a/lib/plausible_web/templates/auth/password_reset_request_form.html.eex +++ b/lib/plausible_web/templates/auth/password_reset_request_form.html.eex @@ -1,11 +1,11 @@ -<%= form_for @conn, "/password/request-reset", [class: "max-w-sm w-full mx-auto bg-white shadow-md rounded px-8 py-6 mt-8"], fn f -> %> -

Reset your password

+<%= form_for @conn, "/password/request-reset", [class: "max-w-md w-full mx-auto bg-white shadow-md rounded px-8 py-6 mt-8"], fn f -> %> +

Reset your password

Enter your email so we can send a password reset link
- <%= email_input f, :email, class: "transition bg-grey-lighter appearance-none border border-transparent rounded w-full p-2 text-grey-darker leading-normal appearance-none focus:outline-none focus:bg-white focus:border-grey-light", placeholder: "user@example.com" %> + <%= email_input f, :email, class: "transition bg-gray-200 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300", placeholder: "user@example.com" %>
<%= if @conn.assigns[:error] do %> -
<%= @conn.assigns[:error] %>
+
<%= @conn.assigns[:error] %>
<% end %> <%= submit "Send reset link →", class: "button mt-4 w-full" %> <% end %> diff --git a/lib/plausible_web/templates/auth/password_reset_request_success.html.eex b/lib/plausible_web/templates/auth/password_reset_request_success.html.eex index e2a23fc16..4669cf670 100644 --- a/lib/plausible_web/templates/auth/password_reset_request_success.html.eex +++ b/lib/plausible_web/templates/auth/password_reset_request_success.html.eex @@ -1,14 +1,12 @@ -
-
-

Success!

-
+
+

Success!

We have sent an email with password reset instructions to <%= @email %> if it exists in our database.
Didn't recieve an email?
-
+
Please check your spam folder and contact uku@plausible.io if the problem persists
diff --git a/lib/plausible_web/templates/auth/register_form.html.eex b/lib/plausible_web/templates/auth/register_form.html.eex index 73b1ecc69..664b8f0bc 100644 --- a/lib/plausible_web/templates/auth/register_form.html.eex +++ b/lib/plausible_web/templates/auth/register_form.html.eex @@ -1,20 +1,18 @@ -<%= form_for @changeset, "/register", [class: "max-w-sm w-full mx-auto bg-white shadow-md rounded px-8 py-6 mb-4 mt-8", id: "register-form"], fn f -> %> -
-

Enter your details to get started

-
+<%= form_for @changeset, "/register", [class: "max-w-md w-full mx-auto bg-white shadow-md rounded px-8 py-6 mb-4 mt-8", id: "register-form"], fn f -> %> +

Enter your details to get started

- <%= label f, :name, "Full name", class: "block text-grey-darker text-sm font-bold mb-2" %> - <%= text_input f, :name, class: "transition bg-grey-lighter appearance-none border border-transparent rounded w-full p-2 text-grey-darker leading-normal appearance-none focus:outline-none focus:bg-white focus:border-grey-light", placeholder: "Jane Doe" %> + <%= label f, :name, "Full name", class: "block text-gray-700 text-sm font-bold mb-2" %> + <%= text_input f, :name, class: "transition bg-gray-200 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300", placeholder: "Jane Doe" %> <%= error_tag f, :name %>
- <%= label f, :email, class: "block text-grey-darker text-sm font-bold mb-2" %> -

No spam, guaranteed.

- <%= email_input f, :email, class: "transition bg-grey-lighter appearance-none border border-transparent rounded w-full p-2 text-grey-darker leading-normal appearance-none focus:outline-none focus:bg-white focus:border-grey-light", placeholder: "example@email.com" %> + <%= label f, :email, class: "block text-gray-700 text-sm font-bold mb-2" %> +

No spam, guaranteed.

+ <%= email_input f, :email, class: "transition bg-gray-200 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:bg-white focus:border-gray-300", placeholder: "example@email.com" %> <%= error_tag f, :email %>
<%= submit "Send activation link →", class: "button mt-4 w-full" %> -

- Already have an account? <%= link("Log in", to: "/login") %> instead. +

+ Already have an account? <%= link("Log in", to: "/login", class: "underline text-gray-800") %> instead.

<% end %> diff --git a/lib/plausible_web/templates/auth/register_success.html.eex b/lib/plausible_web/templates/auth/register_success.html.eex index 42df68006..cb60afc20 100644 --- a/lib/plausible_web/templates/auth/register_success.html.eex +++ b/lib/plausible_web/templates/auth/register_success.html.eex @@ -1,14 +1,12 @@ -
-
-

Success!

-
+
+

Success!

We've sent an activation link to <%= @email %>. Please click on the link to activate your account.
Didn't recieve an email?
-
+
Please check your spam folder and contact uku@plausible.io if the problem persists
diff --git a/lib/plausible_web/templates/auth/user_settings.html.eex b/lib/plausible_web/templates/auth/user_settings.html.eex index dbfd1765c..cd333bbee 100644 --- a/lib/plausible_web/templates/auth/user_settings.html.eex +++ b/lib/plausible_web/templates/auth/user_settings.html.eex @@ -1,31 +1,31 @@ -
-

Subscription Plan

+
+

Subscription Plan

-
+
-
+

Current plan

<%= if @subscription do %>
<%= subscription_name(@subscription) %>
- <%= link("Change plan", to: "/billing/change-plan", class: "text-sm text-indigo font-medium") %> + <%= link("Change plan", to: "/billing/change-plan", class: "text-sm text-indigo-500 font-medium") %> <% else %>
Free trial
- <%= link("Upgrade", to: "/billing/upgrade", class: "text-sm text-indigo font-medium") %> + <%= link("Upgrade", to: "/billing/upgrade", class: "text-sm text-indigo-500 font-medium") %> <% end %>
-
+

Next bill amount

<%= if @subscription do %>
$<%= @subscription.next_bill_amount %>
<%= if @subscription.update_url do %> - <%= link("Update billing info", to: @subscription.update_url, class: "text-sm text-indigo font-medium") %> + <%= link("Update billing info", to: @subscription.update_url, class: "text-sm text-indigo-500 font-medium") %> <% end %> <% else %>
$0
<% end %>
-
+

Next bill date

<%= if @subscription && @subscription.next_bill_date do %> @@ -36,7 +36,7 @@
-

Your usage

+

Your usage

<%= delimit_integer(Plausible.Billing.usage(@conn.assigns[:current_user])) %> @@ -45,46 +45,44 @@ <%= if @subscription && @subscription.cancel_url do %>
- <%= link("Cancel my subscription", to: @subscription.cancel_url, class: "text-indigo text-sm") %> + <%= link("Cancel my subscription", to: @subscription.cancel_url, class: "text-indigo-500 text-sm") %>
<% end %>
-
-
-

Account settings

-
+
+

Account settings

-
+
- <%= form_for @changeset, "/settings", [class: "max-w-xs"], fn f -> %> + <%= form_for @changeset, "/settings", [class: "max-w-sm"], fn f -> %>
- <%= label f, :name, class: "block text-grey-darker text-sm font-bold mb-2" %> - <%= text_input f, :name, class: "transition bg-grey-lighter appearance-none border border-transparent rounded w-full p-2 text-grey-darker leading-normal appearance-none focus:outline-none focus:border-grey-light" %> + <%= label f, :name, class: "block text-gray-700 text-sm font-bold mb-2" %> + <%= text_input f, :name, class: "transition bg-gray-200 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:border-gray-300" %> <%= error_tag f, :name %>
- <%= label f, :email, class: "block text-grey-darker text-sm font-bold mb-2" %> - <%= email_input f, :email, class: "transition bg-grey-lighter appearance-none border border-transparent rounded w-full p-2 text-grey-darker leading-normal appearance-none focus:outline-none focus:border-grey-light" %> + <%= label f, :email, class: "block text-gray-700 text-sm font-bold mb-2" %> + <%= email_input f, :email, class: "transition bg-gray-200 appearance-none border border-transparent rounded w-full p-2 text-gray-700 leading-normal appearance-none focus:outline-none focus:border-gray-300" %> <%= error_tag f, :email %>
<%= submit "Save changes", class: "button mt-4" %> <% end %>
-
+
-

Delete account

+

Delete account

-
+

Deleting your account removes all sites and stats you've collected

<%= if @subscription && @subscription.status == "active" do %> - Delete my account -

Your account cannot be deleted because you have an active subscription. If you want to delete your account, please cancel your subscription first.

+ Delete my account +

Your account cannot be deleted because you have an active subscription. If you want to delete your account, please cancel your subscription first.

<% else %> - <%= link "Delete my account ", to: "/me", method: :delete, class: "button bg-red-dark mt-6", data: [confirm: "Deleting your account cannot be reversed. Are you sure?"] %> + <%= link "Delete my account ", to: "/me", method: :delete, class: "button bg-red-600 mt-6", data: [confirm: "Deleting your account cannot be reversed. Are you sure?"] %> <% end %>
diff --git a/lib/plausible_web/templates/billing/change_plan.html.eex b/lib/plausible_web/templates/billing/change_plan.html.eex index 50204cbbb..0c131755e 100644 --- a/lib/plausible_web/templates/billing/change_plan.html.eex +++ b/lib/plausible_web/templates/billing/change_plan.html.eex @@ -1,17 +1,17 @@ -
-

Change subscription plan

+
+

Change subscription plan

-
+
If you choose to change your plan, your current subscription will be prorated.
10,000 / mo - $6 / mo + $6 / mo <%= if Plausible.Billing.Plans.is?(@subscription, :personal) do %>
- + Selected
<% else %> @@ -20,10 +20,10 @@
100,000 / mo - $12 / mo + $12 / mo <%= if Plausible.Billing.Plans.is?(@subscription, :startup) do %>
- + Selected
<% else %> @@ -32,10 +32,10 @@
1,000,000 / mo - $36 / mo + $36 / mo <%= if Plausible.Billing.Plans.is?(@subscription, :business) do %>
- + Selected
<% else %> diff --git a/lib/plausible_web/templates/billing/upgrade.html.eex b/lib/plausible_web/templates/billing/upgrade.html.eex index 9d8173f24..f3cbe6ccc 100644 --- a/lib/plausible_web/templates/billing/upgrade.html.eex +++ b/lib/plausible_web/templates/billing/upgrade.html.eex @@ -1,7 +1,7 @@ -
-

Upgrade your free trial

+
+

Upgrade your free trial

-
+
<%= cond do %> <% Timex.equal?(@trial_end_date, @today) -> %> Today is the last day of your trial. Please select a plan and enter @@ -25,21 +25,21 @@ All plans are on a monthly basis, cancel any time.

-
+
10,000 / mo - $6 / mo + $6 / mo <%= render("_checkout_button.html", conn: @conn, plan: :personal) %>
100,000 / mo - $12 / mo + $12 / mo <%= render("_checkout_button.html", conn: @conn, plan: :startup) %>
1,000,000 / mo - $36 / mo + $36 / mo <%= render("_checkout_button.html", conn: @conn, plan: :business) %>
@@ -47,7 +47,7 @@
- Questions? Contact <%= link("uku@plausible.io", to: "mailto: uku@plausible.io", class: "text-indigo") %> + Questions? Contact <%= link("uku@plausible.io", to: "mailto: uku@plausible.io", class: "text-indigo-500") %>
diff --git a/lib/plausible_web/templates/error/error.html.eex b/lib/plausible_web/templates/error/error.html.eex index 98054ff61..16c87cc83 100644 --- a/lib/plausible_web/templates/error/error.html.eex +++ b/lib/plausible_web/templates/error/error.html.eex @@ -9,7 +9,7 @@ <%= assigns[:title] || "Plausible · Web analytics" %> "/> - +

<%= @status %>

<%= @message %>
diff --git a/lib/plausible_web/templates/layout/_footer.html.eex b/lib/plausible_web/templates/layout/_footer.html.eex index 265d4b348..15e36d638 100644 --- a/lib/plausible_web/templates/layout/_footer.html.eex +++ b/lib/plausible_web/templates/layout/_footer.html.eex @@ -1,15 +1,15 @@ -
+
<%= img_tag(PlausibleWeb.Router.Helpers.static_path(@conn, "/images/icon/plausible_logo_inverted.png"), style: "height: 2.5rem;") %>

Made by @ukutaht in London, UK

-
    + -
      +
      • Give us Feedback
      • We have a Public roadmap
      • Contact us via email
      • diff --git a/lib/plausible_web/templates/layout/app.html.eex b/lib/plausible_web/templates/layout/app.html.eex index 93a414508..077ec877e 100644 --- a/lib/plausible_web/templates/layout/app.html.eex +++ b/lib/plausible_web/templates/layout/app.html.eex @@ -8,47 +8,47 @@ "> <%= assigns[:title] || "Plausible · Simple, open-source web analytics" %> "/> - "/> + <%= render("_tracking.html", assigns) %> - + <%= render("_svg_icons.html") %> <%= if get_flash(@conn, :success) do %> -
ReferrerVisitorsBounce rateReferrerVisitorsBounce rate