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

Import tailwind #783

Merged
merged 4 commits into from
Oct 7, 2020
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
2 changes: 1 addition & 1 deletion app/assets/stylesheets/homepage.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

154 changes: 154 additions & 0 deletions app/assets/stylesheets/tailwind/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,154 @@
@tailwind base;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand this file is a straight copy/paste for now. Do you plan to change it later? I think it's not Tailwind's spirit to add custom classes like feature-box, but instead, rely on utilities as much as possible.

It would be a good idea to extract the CSS where we apply classes to a different CSS file as well.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, my next task is to figure out how we want to split up the CSS, do components, etc, and adjust the source / target input / outputs accordingly.


html {
font-size: 62.5%;
}

h1 {
@apply text-xl font-sans pb-10;
}

h2 {
@apply text-lg font-sans pb-6;
}

a {
@apply underline text-base;
}

p {
@apply text-base leading-tight;
}

li {
@apply text-base leading-tight;
}

.btn-blue {
background-color: theme("colors.blue.lighter");
@apply py-4 px-5 font-bold no-underline border-b-2;
}

.btn-light {
color: theme("colors.green.default");
border-color: theme("colors.green.default");
background-color: theme("colors.white.default");
@apply py-4 px-6 font-bold no-underline border-2;
border-bottom: 4px solid theme("colors.green.dark");
}

@tailwind components;

@tailwind utilities;

.input {
border-color: #000;
@apply border-solid border-2 py-3 px-2 text-smaller;
}

.flip {
transform: rotate(-180deg);
transition: all 0.5s ease;
padding-top: 2px;
}

label {
@apply block text-smaller pb-2;
}

@variants focus {
.input {
@apply outline-none;
}
}

button:focus{
outline: none;
}

.line-under {
text-underline-position: under;
}

.feature-box {
@apply w-3/4;
}

@screen lg {
.feature-box {
@apply w-1/3;
}
}

.quote-box {
@apply text-small mb-10;
}

.quote-box div:first-child {
@apply font-bold italic mb-2;
}

/* form(s) */
.form-group {
@apply mb-4;
}

.form-group-error {
@apply mr-4 pl-4 border-l-4 border-red;
}

.form-control-error {
@apply border-4 border-red;
}

.error-message {
@apply block text-red text-base;
}

/* honeypot field*/
.phone {
position: absolute !important;
height: 1px;
width: 1px;
overflow: hidden;
clip: rect(1px 1px 1px 1px); /* IE6, IE7 */
clip: rect(1px, 1px, 1px, 1px);
white-space: nowrap; /* added line */
}

.skiplink:focus {
background-color: #ffbf47;
outline: 3px solid #ffbf47;
}

.skiplink {
position: absolute;
left: -9999em;
}

.skiplink:focus,
.skiplink:visited {
color: #0b0c0c;
}

.skiplink:focus {
left: 0;
z-index: 1;
}

#skiplink-container {
text-align: center;
background: #0b0c0c;
}

#skiplink-container div {
text-align: left;
margin: 0 auto;
max-width: 1020px;
}

#skiplink-container .skiplink {
display: -moz-inline-stack;
display: inline-block;
margin: 0.75em 0 0 30px;
}
Loading