Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: re-enable tailwind base class on extension popup #31

Merged
merged 3 commits into from
Apr 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import logoIcon from "../../assets/opensauced-icon.svg";
import "../../index.css";
import { createHtmlElement } from "../../utils/createHtmlElement";
import logoIcon from "../../../assets/opensauced-icon.svg";
import "../../content-scripts.css";
import { createHtmlElement } from "../../../utils/createHtmlElement";

export const InviteToOpenSaucedButton = () => {
const inviteToOpenSaucedButton = createHtmlElement("a", {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import "../../index.css";
import { createHtmlElement } from "../../utils/createHtmlElement";
import emailSocialIcon from "../../assets/mail-icon.svg";
import twitterSocialIcon from "../../assets/twitter-icon.svg";
import linkedInSocailIcon from "../../assets/linkedin-icon.svg";
import "../../content-scripts.css";
import { createHtmlElement } from "../../../utils/createHtmlElement";
import emailSocialIcon from "../../../assets/mail-icon.svg";
import twitterSocialIcon from "../../../assets/twitter-icon.svg";
import linkedInSocailIcon from "../../../assets/linkedin-icon.svg";

interface Socials {
emailAddress?: string;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import logoIcon from "../../assets/opensauced-icon.svg";
import "../../index.css";
import { createHtmlElement } from "../../utils/createHtmlElement";
import logoIcon from "../../../assets/opensauced-icon.svg";
import "../../content-scripts.css";
import { createHtmlElement } from "../../../utils/createHtmlElement";

export const ViewOnOpenSaucedButton = (username: string) => {
const viewOnOpenSaucedButton = createHtmlElement("a", {
Expand Down
27 changes: 27 additions & 0 deletions src/content-scripts/content-scripts.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
/*
style for content-scripts
not using tailwindcss base styles because it's interfering with the github page styles
*/

@tailwind components;
@tailwind utilities;

* {
box-sizing: border-box;
margin: 0px;
padding: 0px;
}

body {
margin: 0;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen",
"Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue",
sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}

code {
font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New",
monospace;
}
2 changes: 1 addition & 1 deletion src/main.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react'
import ReactDOM from 'react-dom/client'
import App from './App'
import './index.css'
import './popup.css'

ReactDOM.createRoot(document.getElementById('root')!).render(
<React.StrictMode>
Expand Down
23 changes: 23 additions & 0 deletions src/popup.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
@tailwind base;
@tailwind components;
@tailwind utilities;

* {
box-sizing: border-box;
margin: 0px;
padding: 0px;
}

body {
margin: 0;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen",
"Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue",
sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}

code {
font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New",
monospace;
}
4 changes: 2 additions & 2 deletions src/utils/dom-utils/inviteToOpenSauced.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { InviteToOpenSaucedButton } from "../../components/InviteToOpenSauced/InviteToOpenSaucedButton";
import { InviteToOpenSaucedModal } from "../../components/InviteToOpenSauced/InviteToOpenSaucedModal";
import { InviteToOpenSaucedButton } from "../../content-scripts/components/InviteToOpenSauced/InviteToOpenSaucedButton";
import { InviteToOpenSaucedModal } from "../../content-scripts/components/InviteToOpenSauced/InviteToOpenSaucedModal";
import { getTwitterUsername, getLinkedInUsername } from "../urlMatchers";

const injectOpenSaucedInviteButton = (username: string) => {
Expand Down
2 changes: 1 addition & 1 deletion src/utils/dom-utils/viewOnOpenSauced.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ViewOnOpenSaucedButton } from "../../components/ViewOnOpenSaucedButton/ViewOnOpenSaucedButton";
import { ViewOnOpenSaucedButton } from "../../content-scripts/components/ViewOnOpenSaucedButton/ViewOnOpenSaucedButton";

const injectViewOnOpenSaucedButton = (username: string) => {
const viewOnOpenSaucedButton = ViewOnOpenSaucedButton(username);
Expand Down