diff --git a/assets/less/app.less b/assets/less/app.less index 2c3fdf1..3a57a4f 100644 --- a/assets/less/app.less +++ b/assets/less/app.less @@ -36,3 +36,8 @@ div#status { .box-shadow(inset 0 -2px 0 @brand-danger); } } + +.space-between { + display: flex; + justify-content: space-between; +} diff --git a/src/components/Options.tsx b/src/components/Options.tsx index aa03784..6517f3b 100644 --- a/src/components/Options.tsx +++ b/src/components/Options.tsx @@ -14,7 +14,9 @@ interface State { loading: boolean; loggingStyle: string; loggingType: string; + socialMediaSites: string; theme: string; + trackSocialMedia: boolean; whitelist: string; } export default function Options(): JSX.Element { @@ -27,7 +29,9 @@ export default function Options(): JSX.Element { loading: false, loggingStyle: config.loggingStyle, loggingType: config.loggingType, + socialMediaSites: config.socialMediaSites, theme: config.theme, + trackSocialMedia: config.trackSocialMedia, whitelist: '', }); @@ -39,7 +43,9 @@ export default function Options(): JSX.Element { blacklist: '', loggingStyle: config.loggingStyle, loggingType: config.loggingType, + socialMediaSites: config.socialMediaSites, theme: config.theme, + trackSocialMedia: true, whitelist: '', }); setState({ @@ -48,7 +54,9 @@ export default function Options(): JSX.Element { blacklist: items.blacklist as string, loggingStyle: items.loggingStyle as string, loggingType: items.loggingType as string, + socialMediaSites: items.socialMediaSites as string, theme: items.theme as string, + trackSocialMedia: items.trackSocialMedia as boolean, whitelist: items.whitelist as string, }); }; @@ -73,6 +81,8 @@ export default function Options(): JSX.Element { const theme = state.theme; const loggingType = state.loggingType; const loggingStyle = state.loggingStyle; + const trackSocialMedia = state.trackSocialMedia; + const socialMediaSites = state.socialMediaSites; // Trimming blacklist and whitelist removes blank lines and spaces. const blacklist = state.blacklist.trim(); const whitelist = state.whitelist.trim(); @@ -83,7 +93,9 @@ export default function Options(): JSX.Element { blacklist, loggingStyle, loggingType, + socialMediaSites, theme, + trackSocialMedia, whitelist, }); @@ -95,7 +107,9 @@ export default function Options(): JSX.Element { displayAlert: true, loggingStyle, loggingType, + socialMediaSites, theme, + trackSocialMedia, whitelist, }); await logUserIn(state.apiKey); @@ -234,6 +248,68 @@ export default function Options(): JSX.Element { +
+ Social Media Sites +
+