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

Рахимянов Эмиль #11

Open
wants to merge 11 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 6 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
Binary file added HFF Clip Hanger.ttf
Binary file not shown.
Binary file added Rns_Bobo_Dylan.otf
Binary file not shown.
114 changes: 114 additions & 0 deletions index.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,114 @@
@font-face
{
font-family: 'HFF Clip Hanger';
src: url('HFF Clip Hanger.ttf');
}

@font-face
{
font-family: 'Bobo Dylan';
src: url('Rns_Bobo_Dylan.otf');
}

figure,
.firstLine,
.vertical,
blockquote,
h1
{
text-align: center;
}

section
{
column-count: 4;
column-rule: 1px dotted #ddd;
column-fill: auto;
-webkit-column-count: 4;
-moz-column-count: 4;
-webkit-column-fill: auto;
-moz-column-fill: balance;
-webkit-column-rule: 1px dotted #ddd;
-moz-column-rule: 1px dotted #ddd;
}

figure
{
break-inside: avoid-column;
}

figure img
{
width: 100%;
}

.first-line
{
border-bottom: 3px #000 double;
border-top: 3px #000 double;
margin-bottom: 5px;
}

.vertical
{
display: inline-block;
Copy link

Choose a reason for hiding this comment

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

А зачем этот элемент делать инлайновым?

float: left;
width: .85em;
word-break: break-all;
border-radius: 5px;
border: 1px solid #000;
height: auto;

Choose a reason for hiding this comment

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

Кажется это лишнее

Copy link

Choose a reason for hiding this comment

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

Объясни, пожалуйста, зачем ты здесь используешь height: auto?

letter-spacing: .2em;
margin: 10px;
padding: 3px;
page-break-inside: avoid;
break-inside: avoid;
-webkit-column-break-inside: avoid;
}

section article:nth-child(2n) blockquote
{
border-bottom: 1px #000 solid;
border-top: 1px #000 solid;
}

section article:nth-child(2n+1) blockquote
Copy link

Choose a reason for hiding this comment

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

Здесь nth-child оставил. Использование класса значительно упростит селектор и повторное использование таких границ. Например, понадобится использовать такой стиль в другом порядке и тогда надо будет лишь проставить классы у нужных элементов, а не менять селектор. Ведь изменить класс проще?

{
border-bottom: 3px #000 double;
border-top: 3px #000 double;
}

article p:first-of-type::first-letter
{
font-weight: bold;
}

.font-abril-fatface
{
font-family: 'Abril Fatface';
}

.font-clip-hanger
{
font-family: 'HFF Clip Hanger';
}

.font-bobo-dylan
{
font-family: 'Bobo Dylan';
}

.font-oswald
{
font-family: 'Oswald';
}

.font-fjalla-one
{
font-family: 'Fjalla One';
}

.font-fascinate-inline
{
font-family: 'Fascinate Inline';
}
107 changes: 101 additions & 6 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,104 @@
<!DOCTYPE html>
<html lang="ru">
<head>
<meta charset="utf-8">
<title>Задача «DeLorean DMC-12»</title>
</head>
<body>
</body>
<head>
<meta charset="utf-8">
<title>Задача «DeLorean DMC-12»</title>
<link href="http://tinyurl.com/ycoym3ls" rel="stylesheet">
Copy link

Choose a reason for hiding this comment

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

А давай не будем пользоваться чем-то уже готовым, а сами подключим нужные тебе шрифты. Пока что это курсы и здесь надо научиться понимать как все работает

Copy link
Author

Choose a reason for hiding this comment

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

Там используются как шрифты из репозитория так и с гугла

Copy link

Choose a reason for hiding this comment

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

Не вижу в этом проблемы. Почему бы просто не подключить те же шрифты?

<link rel="stylesheet" href="index.css">
</head>
<body>
<main>
<h1 class="font-abril-fatface">Lorem Ipsum</h1>
<header class="first-line font-clip-hanger">
Neque porro quisquam est qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit...
</header>
<section>
<article>
<h3 class="font-bobo-dylan">
The standard Lorem Ipsum passage, used since the 1500s
</h3>
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim
veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
commodo consequat. Duis aute irure dolor in reprehenderit in voluptate
velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat
cupidatat non proident, sunt in culpa qui officia deserunt mollit
anim id est laborum.
</p>
</article>
<article>
<h3 class="font-oswald">
Section 1.10.32 of "de Finibus Bonorum et Malorum",
written by Cicero in 45 BC
</h3>
<aside class="vertical font-fascinate-inline">
Where &nbsp; can &nbsp; I &nbsp; get &nbsp; some?
</aside>
<p>
Sed ut perspiciatis unde omnis iste natus error sit voluptatem
accusantium doloremque laudantium, totam rem aperiam, eaque ipsa
quae ab illo inventore veritatis et quasi architecto beatae vitae dicta
sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut
odit aut fugit, sed quia consequuntur magni dolores eos qui ratione
voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum
quia dolor sit amet, consectetur, adipisci velit, sed quia non
numquam eius modi tempora incidunt ut labore et dolore magnam aliquam
quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem
ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur?
Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse
quam nihil molestiae consequatur, vel illum qui
dolorem eum fugiat quo voluptas nulla pariatur?
</p>
<blockquote>
Nemo enim ipsam voluptatem quia voluptas
sit aspernatur aut odit aut fugit
</blockquote>
<p>
Sed ut perspiciatis unde omnis iste natus error sit voluptatem
accusantium doloremque laudantium, totam rem aperiam, eaque ipsa
quae ab illo inventore veritatis et quasi architecto beatae
vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia
voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur
magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro
quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur,
adipisci velit, sed quia non numquam eius modi tempora incidunt
ut labore et dolore magnam aliquam quaerat voluptatem.
Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis
suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur?
Quis autem vel eum iure reprehenderit qui in ea voluptate
velit esse quam nihil molestiae consequatur, vel illum qui
dolorem eum fugiat quo voluptas nulla pariatur?
</p>
<figure>
<img src="lenna.jpg" alt="lenna.jpg" title="playboy">
<figcaption>This is lenna.jpg</figcaption>
</figure>
</article>
<article>
<h3 class="font-fjalla-one">1914 translation by H. Rackham</h3>
<p>
But I must explain to you how all this mistaken idea of
denouncing pleasure and praising pain was born and I will
give you a complete account of the system, and expound
the actual teachings of the great explorer of the truth,
the master-builder of human happiness. No one rejects,
dislikes, or avoids pleasure itself, because it is pleasure, but because
those who do not know how to pursue pleasure rationally
encounter consequences that are extremely painful. Nor again
is there anyone who loves or pursues or desires to obtain
pain of itself, because it is pain, but because occasionally
circumstances occur in which toil and pain can procure
him some great pleasure. To take a trivial example,
which of us ever undertakes laborious physical exercise,
except to obtain some advantage from it? But who has any right
to find fault with a man who chooses to enjoy a pleasure
that has no annoying consequences, or one who avoids
a pain that produces no resultant pleasure?
</p>
<blockquote>I will give you a complete account of the system</blockquote>
</article>
</section>
</main>
</body>
</html>
Binary file added lenna.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.