the works

The Shakespeare region is the main region. If we could only do one thing, it would be this.

1 the happy path

Since this is central focus of the site, it’s important that it lay on the “happy path”: the place the visitor will fall into if at all indisposed to decision-making.

So, we put it in the “hallway,” as we might call it, that is, the thing you end up going down if you just move forward.

If we want the space to be imageable, it can’t go on forever. Yet, it is extremely difficult to assign a definite size to any content—even a single word—given the many shapes and sizes of our little screens. So while I want to think of the total size of the entryway in terms of “viewport heights,” there has to be some flexibility.

the-Shakespeare-region.svg

So, how big should it be? That depends of course on what’s in it.

So… what’s in it?

Of course, we have to have the boring old list of the plays.

#exhibit <prepend>
	<section id="Shakespeare">
		<<Shakespeare region heading>>
		<<Shakespeare region message>>
		<<the works>>
	</section>
</prepend>

The name of that file important for ordering. Without “exhibit-”, “Shakespeare” would sort after it, and “regions” wouldn’t exist yet in the sequence of home changes.

Note that in the following rules, we assume that the “container” of the Shakespeare region takes up the entire viewport. Specifically, we use the vw and vh units in some places, where we’re not able to use references to the positioning parent. So this would be messed-up if we tried to reposition the parent so that it did anything other than occupy the whole viewport.

@import transition-timings
@import order_of_exhibit_layers
@import colors

#Shakespeare
	// But note that this is also positioned by transform
	position absolute
	top 0
	left 0
	width 100%

	// The Shakespeare region is three screens high.
	height 300vh

	// This also creates a stacking context.
	z-index $entrywayLayer + 1

	// The Shakespeare region begins just below the fold.
	//transform translateY(100vh)
	top 100vh

	default-transition('top') // And does so smoothly

	box-shadow 0 0 1em               // The Shakespeare region is floating in space.

	background rgba($worksLightColor, .8)

// TEMP, these are shared between a couple of the below
$playsHeadingHeight = 3.25rem
$genresHeight = 2.5rem

@import exit-links
@import colors
@import docking
@import paper
@import fonts
@import plain_list
@import signs
@import thumb-metrics
@import transition-timings
@import typesetting
@import pointing

<<Shakespeare region styles>>
<<the play signs  styles>>
<<play-genres-styles>>
<<the poems styles>>

2 region basics

Actually, I’m looking at this with the heading disabled, and it’s kind of nice.

Also, there are no other regions now, at least not defined here.

All of the regions have some things in common.

2.1 the Shakespeare region heading

<h1 id="Shakespeare-heading">
  <a href="/#Shakespeare">Shakespeare</a>
  <!-- <a href="/#entryway" class="exit-link"><span class="exit-link-text" /></a> -->
</h1>

Visually, it’s a large title box.

@import region_headings

#Shakespeare-heading
	region_heading()
	has-exit-link()
	// These would be set by region-heading-link, but we don't apply it to the
	// link in this case because we don't want most of its defaults
	// (e.g. padding.)
	text-align center
	letter-spacing -.04em

	scale-up(at, to)
		@media (min-width at) and (min-height at)
			font-size to

	scale-up(30rem, 300%)
	scale-up(40rem, 400%)

	background $worksColor

2.2 the Shakespeare region message

<header id="Shakespeare-region-message" class="region-message">
  <p>An edition of the <a href="/plays">plays</a> and <a href="/poems">poems</a>
  of <a href="/#Shakespeare">Shakespeare</a>.</p>
</header>

How does this look different than the other region messages?

#Shakespeare .region-message
	width $readingRems      // The other ones are narrower
	margin 0 auto           // Centered horizontally
	max-width 100%
	font-weight normal      // beat .region-message, which is too light.
	color $worksDarkColor

3 “breathing room” : something before the works

I’ll come to the works in a moment.

Yes, the mission statement says that Shakespeare’s actual works must be “front and center.” But tarry a little.

There are over forty works listed here. Coming from the entryway, where there are only four ways to go, this could be a little overwhelming.

Yeah, some people will know exactly what they’re looking for. But making decisions requires an emotional effort.

People unfamiliar with the plays will not have a basis for choosing one play over another (beyond what is suggested by their titles), the presentation of forty choices would threaten the “happy path” nature of this region, if it were the first thing presented.

All I can say for sure is that, I don’t know right now what will ultimately be best here. It’s a confined space. It’s somewhat the same principle as at the entryway. I want to use this bounded space to provide ways into unbounded spaces.

And what are these unbounded spaces?

They would include emotional indexes to the works. Fathers, mothers, daughters. Ways to identify with the roles. So many, really… I can’t even identify the kinds of things that would be good. But yeah, ways of featuring content.

Also guides. Guides are kind of like resources… this gets hazy. The idea of a guide is that it’s a document that talks about various locations in the site.

#the_works <before>
<div id="Shakespeare-happy">
	<a id="the-works-link"
		 class="happy-link"
		 href="#the_works">
		<span>the works</span>
	</a>
</div>
</before>
@import colors
@import centering
@import pointing
@import signs
@import arrows
@import thumb-metrics

#Shakespeare-happy
	text-align center
	position relative
	min-height 100vh

.happy-link
	display inline-block

	// Use em's so you can scale up with font size
	circle(unit($thumbRems, em))

	text-align center
	line-height .8
	font-weight 200

	position relative                       // so you can position arrow
	span
		horizontally-center()
		bottom calc(50% - .5rem)

	// It's a sign!
	color $signTextColor
	background $worksColor
	box-shadow 0 0 .25em #111
	+user_pointing_at()
		background $contextColor

	// The text is absolutely positioned, so this must be also
	+arrow-after-pointing(down)
		horizontally-center()
		top calc(50% + 1.5rem)

	// It grows!
	scale-up(at, to)
		@media (min-width at) and (min-height at)
			font-size to

	scale-up(25rem, 125%)
	scale-up(30rem, 150%)

4 the works

And here we come to the heart of the exhibit.

4.1 overview of the works

We face the “problem” of presenting all of Shakespeare’s works in one place—a problem Shakespeare never faced.

We want to arrange the works in some pleasing way. We’ve reserved an area called #the_works for doing this. Since it’s going to contain primarily links, we consider it a “navigational” section. In HTML5 terms, this communicates that it’s not a part of the document flow, so as long as this is a nav, it shouldn’t contain much if any narrative text.

This part of the Shakespeare region is fixed in size, so we can use a positioned container. And since we’re leaving some “breathing room”, it’s offset downward by one screen height.

@import docking
#the_works
	position relative                       // It's a positioning container
	height 150vh                            // And it is one and a half screens tall
	// But if the screen is really small, it still needs it to be readable.
	min-height 24em

Note that #the_works is an invisible container—we’re only using it to make the layout of its contents easier.

This is supposed to be an “overview,” so we’d like for everything to be visible at once. But some screens are just too small to list all of the works at once. We’ll make the best arrangement that we can, while leaving it clear that the material scolls when it doesn’t fit.

4.2 present the plays and poems

Let’s start by dividing the works into the plays and the poems. That’s pretty uncontroversial. Besides, our logical structure already makes this distinction; that is, we put them under separate URL’s.

#the-plays-section will be simply a list of the plays and genres, with a heading:

<section id="the-plays-section">
	<h1 id="the-plays-heading">
		<a id="the-plays-heading-link" href="/plays">the plays</a>
	</h1>
	<<a list of the plays>>
	<<a list of the play genres>>
</section>

The poems are similar, but even simpler:

<section id="the-poems-section">
	<h1 id="the-poems-heading">
		<a id="the-poems-heading-link" href="/poems">the poems</a>
	</h1>
	<div id="the-poems">
		<a class="poem-sign" href="/poems/sonnets">The sonnets</a>
		<a class="poem-sign" href="/poems/Ven">Venus &amp; Adonis</a>
		<a class="poem-sign" href="/poems/Luc">The Rape of Lucrece</a>
		<a class="poem-sign" href="/poems/PhT">The Phoenix and the Turtle</a>
		<a class="poem-sign" href="/poems/LC">A Lover’s Complaint</a>
		<a class="poem-sign" href="/poems/PP">The Passionate Pilgrim</a>
	</div>
</section>

The plays and poems are kind of “subregions”.

plays-and-poems.svg
// Leave room for the beacon
@import beacon-metrics
#the-plays-section
#the-poems-section
	position absolute
	top 0
	height $beaconRems
	margin-top $beaconMarginRems * 2 + $beaconRems

#the-plays-section
	right 0
	width 80%

#the-poems-section
	left 0
	right 80%
	margin-right .5em

#the-plays-heading
	font-size 500%
	margin-top -.2em
	white-space nowrap
	letter-spacing -.07em
	margin-left -.05em

	// Get in front of genre names
	position relative
	z-index 1

@import typesetting
#the-poems-heading
	margin-top 0                            // beat heading default
	compact-spacing()

#the-poems
	left 0
	width 100%

The headings for “the poems” and “the plays” use the “paper” font, which is defined in the typefaces as “IM Fell DW Pica.” The metrics for the headings are somewhat tuned to that choice.

@import fonts
#the-plays-heading
#the-poems-heading
	paper-font()
	font-weight normal                      // beat heading default
	color rgba(black, .6)

Actually, the body font “Lato” looks quite there, as it does most places. But I wanted to make sure that IM Fell was loaded right away, because otherwise it would load on-demand when transitioning to a play, where it’s used in the entryway sign, and the transition was almost always interrupted by a very noticeable reflow when it finished loading. I’m happy that this solves that problem, while adding some character to these headings.

@import colors
#the-plays-section
#the-poems-section
	background $worksLightColor
	box-shadow .25em .25em .5em #111

Here we pipe an index of the works into a template that creates links in #the-plays:

<ul id="the-plays-signs">
	<xslt name="render-play-signs"
				input="/static/doc/works-index.xml" />
</ul>

The play “signs” are just links. These links are always present, in every part of the site, even when they’re not visible.

<xsl:template match="/works-index">
	<xsl:for-each select="plays/play">
		<li class="play-sign" id="play-{@key}-sign">
			<a href="/plays/{@key}" class="play-sign-link">
				<i class="play-sign-title">
					<xsl:value-of select="@unique_title"/>
				</i>
			</a>
		</li>
	</xsl:for-each>
</xsl:template>
#the-poems
	position absolute
	top $genresHeight + $playsHeadingHeight
	bottom 0

.poem-sign
	dock-top()
	height 2em
	background $paperColor
	padding .25em .5em
	transform-origin top center
	box-shadow 1px 1px 2px #111
	z-index 1
	line-height 1
	overflow hidden

	@media (max-width 30rem)
		height 3.5em
		font-size 80%
		hyphens auto
	@media (max-width 25rem)
		font-size 80%
	@media (max-width 20rem)
		font-size 75%

	+user_pointing_at()
		background $worksLightColor
	// Why not just make these a flow-positioned list, anyway?
	for i in (1..6)
		&:nth-child({i})
			transform translateY(100% * (i - 1))

4.3 the play genres

The best actors in the world, either for tragedy,
comedy, history, pastoral, pastoral-comical,
historical-pastoral, tragical-historical, tragical-
comical-historical-pastoral, scene individable, or
poem unlimited: Seneca cannot be too heavy, nor
Plautus too light. For the law of writ and the
liberty, these are the only men.
Hamlet

Genre means “type,” basically. But of course, type is itself a metaphor (from typesetting), as it refers to the likeness of things. So, as usual, it’s most instructive to look at the word’s roots. Our friend the Online Etymology Dictionary has “genre” as

1770, “particular style of art,” a French word in English (nativized from c. 1840), from French genre “kind, sort, style” (see gender (n.)).1

Pursuing “gender,” we end up at “genus,”

from PIE root *gene- “to produce, give birth, beget,” with derivatives referring to family and tribal groups.2

So the “genre” of a work of art is something that is bound up in its conception, something “genetic.” It’s not something that critics and editors later decide to tack on (although they may argue about it); it’s a quality—a heritage—that’s present during the author’s work. And it’s not easily separated from the thing.

When it comes to genre, I always think about Northrop Frye’s statement that “the category judgement precedes the value judgement.” Actually I have no idea whether Northrop Frye said this, but I had a film teacher who cited it whenever talking about film criticism. Before you can judge whether something is good, you have to judge what it is, or what it’s trying to do.

(There’s this and this.)

Anyway, all this is to say that genres have some authority. Shakespeare was thinking about specific genres, which had conventions and expectations.

That said, I’ve been careful not to overemphasize genres. For one thing, Shakespeare himself rarely attributed a genre to a play explicitly. In the cases where he did (or probably did), it was through the title. And even in these cases, his choice doesn’t usually agree with what we say today. In particular, several of the “histories” (as we call them) are called “tragedie” in their original titles.

There is also the matter of the “romances.”

Here are some of my earlier notes on this.

Regarding the groups: in for a penny, in for a pound.

  • the groups serve as a memory aid
  • the groups serve as a navigational aid
  • the groups serve as an emotional connection (for aiding choice). It’s much easier to choose among four groups with names like comedy, &c, than to choose among 40 items whose names may all be unfamiliar.

It’s a tradeoff like anything else. Asimov’s grouping is the only I’ve seen which substantially (and interestingly) departs from this model. His grouping is perhaps, in principle, less arbitrary, at least with respect to the definition of the groups. But when it comes to actually placing plays into the groups, you have just as much gray area.

Anyway, let’s provide a list of the genres as we identify them:

<ul id="the-plays-genres">
	<play-genres>
		<comedy plural=" comedies " />
		<tragedy plural="tragedies" />
		<history plural="histories" />
		<romance plural="romances " />
	</play-genres>
</ul>

Although note that we these link targets don’t actually exist right now.

That uses a little template, which just renders a link for each genre.

<xsl:template match='play-genres'>
	<xsl:for-each select="*">
		<li class='play-genre {name()}'>
			<a class='play-genre-link'>
				<xsl:value-of select='@plural' />
			</a>
		</li>   
	</xsl:for-each>
</xsl:template>
@import signs
@import typesetting
#the-plays-genres
	plain-list()
	hug-parent(top: $playsHeadingHeight)
	z-index 0
	sign-text-color()

@import typesetting
.play-genre
	// These will be positioned with the corresponding play signs.
	position absolute
	height $genresHeight
	// To wit, for "romances", which can otherwise overflow viewport and cause a
	// horizontal scrollbar.
	clip-text()

@import centering
.play-genre-link
	// Not needed as long as these are not actually links
	//hug-parent()
	compact-spacing()
	vertically-center()

	// The text is centered, so we get effective padding from the fixed size.
	padding-left 0

	font-weight 200
	text-align left
	line-height 1
	font-size 120%

	scale_to(scale, at = min, of = 0)
		@media ({at}-width of)
			font-size scale

	scale_to(150%, at: min, of: 30rem)
	scale_to(175%, at: min, of: 35rem)

4.4 the (mythical?) flags

I find no hard evidence for the claim made around the internet that various-colored flags were used to indicate to playgoers the type of play that was being put on.

While in the private theatres shows took place in the early evening, in the public theatres plays took place in the afternoon: a Flag raised in the morning over the theatre – visible from the City of London – indicated that there would be a performance. A white flag signalled a comedy, a purple flag a history, and a black flag a tragedy.

English Renaissance Drama: A Very Brief Introduction to Theatre and Theatres by C. W. R. D. Moseley

https://books.google.com/books?id=h1qac9NeXRoC&lpg=PA26&ots=NQwIxGxyBh&dq=%22white%20flag%22%20%22comedy%22%20%22history%22%20%22black%20flag%22&pg=PA26#v=onepage&q=%22white%20flag%22%20%22comedy%22%20%22history%22%20%22black%20flag%22&f=false

Anyway, this would at least be some non-arbitrary, historically-founded, and visual basis for classifying the plays—if indeed that’s what it were.

4.5 the play signs

One matter over which I hesitated for a considerable length of time was the question of the order of presentation of the plays.

Isaac Asimov, Asimov’s Guide to Shakespeare, 1970

The plays are the main feature of willshake, and, like Asimov, I’ve spent considerable time thinking about how they should be presented.

4.5.1 more thinking

Isaac Asimov, in his Guide to Shakespeare, gives a rationale for his choice of arrangement:

Since I am chiefly interested in this book in the historical, legendary, and mythological background of the events described in the various plays, I have decided to place the plays in the chronological order of those historical events as far as possible.

On what basis could we form a similarly cogent rationale? What is it that we are “chiefly interested” in?

Beauty and pleasure, of course. Bringing the beauty and pleasure of Shakespeare to new media. We have already said that this “new media” is in its infancy, and that the best way to understand it is to create it. That doesn’t give us much to go on. But we also say that it’s about using more human capabilities… more than just the interpretation of symbols. It’s considered a bad practice to make people “think”, and to make people “choose,” which is an emotionally demanding act. On the other hand, we want to make something useful, and something that is easy and pleasurable to use when you do know what you’re looking for.

With all that said, we have some practical constraints.

surveyability
(for lack of a better term) We’d like to fit all of the names on the screen at once, when the screen is able to display them readably. This is something we talk about elsewhere. What would we do if we had infinite space? We’d of course, still want all of the plays/works to be represented in view. Since even a tablet screen is capable of showing forty titles at once (albeit without much liberty of arrangement), this is mostly a matter of degree and not kind, at least above the phone-size. For phones, of course, some of our ideals must (as usual) give way to the severe size constraints.
adaptibility
We can’t count on a specific layout, anyway. What we have to describe is more of a “program” or set of rules for conveying essentially the same information in various physical configurations.
taxonomy
We acknowledge that the categories of the plays are useful, though not authoritative. For the purpose of arrangement, we’re talking about an exclusive grouping—that is, not a tagging scheme where something can be filed in more than one place.
chronology
We recognize the chronology of the plays as perhaps the only non-arbitrary style of arrangement, but not one that is undertaken without the need for editorial judgement, nor one that is quite useful to general audiences, nor one that quite helps with the design problem. (The “fitting” problem.)
popularity
We acknowledge that not all of the plays/works are equally popular, whether with audiences, actors, producers, critics, or any other respondants. Yet, we would like to abstain from either making or transmitting such judgements.
affordability
Further to the “fitting” problem, it’s also important that signs not be too small to touch. This is especially irritating on mobile screens. You try to hit one sign, and you get another. It’s unpleasant.

Squares are better for this fat-fingering problem. But titles are hard to break into squares, because they vary in length—both the number of words, and the length of the words. You can’t just force all titles to balance well in any given aspect ratio. Single lines are the only equalizer.

speed
We can’t solve this problem with more bytes. This is on the home page—and every page. We have to do more with what we have.

Maybe it’s necessary to separate the aims of providing navigation and information. Yes, we’ve worked very hard to keep these aims flowing from one source. But what? But constraints?

Again, what would we do if we had infinite space?

We could include more. We could show artwork about each of the plays (such as on the JSTOR thing), or quotes from the plays, or quotes about the plays, or have links to songs, or parts of the recordings. I kind of like the idea of featuring some interesting thing from each play, regardless of what type, but that would take you to some random place in the middle of the play. Plus,

I suppose that for the “pain of choice” thing, we could include a “featured play” every month. This would give me time to develop special content for that play, while giving a kind of default path to people who just want to check things out without wanting to choose among forty plays. Yeah, this means that it’s no longer deterministic, and it wouldn’t apply to the app, and so on. But it wouldn’t be hard to do, and it would actually solve a problem.

But come on—are you really going to change what you have?

Yes, I really am. I’m not satisfied with it. It just doesn’t hang together.

I’m thinking about the square thing, though. This would theoretically give you more flexibility to group things differently. I’m not really sure that’s a feature, though. I’m already content with the arrangement within groups.

Think of it this way. You have ≈42 things. That’s about 6x7 or 7x6. Screens are not square. They tend to be 4x3 or in that neighborhood. But close enough. If we target approximately a square, we can work with any orientation, given some margins.

That’s well and good, but we don’t have evenly distributed groups, anyway. And besides, even distributions are harder to remember. Having a “jagged” grouping means that you can visually associate an item with a longer or shorter group. Equalizing things destroys that information.

Also, having a single column within each group allows you to convey a rough chronology with each group. Moving to two columns would destroy that.

Yet… we could use this arrangement to make rough sub-groups (the early comedies, etc). This is of course just the opposite of everything we just said about avoiding such editorialism. But maybe without that, it wouldn’t be clear why the titles are not arranged alphabetically within the groups (i.e. there’s no sign of it being a chronology).

One thing I like about these more “squarish” signs is that they suggest a kind of “mini screen,” which is just what the plays are: another world, which takes over the screen, and to which the signs are portals.

The problem with it, as you might have predicted, is that you “waste” a lot of space. If you have a square sign that is large enough for a title like “A Midsummer Night’s Dream,” it’s necessarily going to leave a lot of empty space when used on a title like “Hamlet,” which is to say, like most of the tragedies.

Still todo:

  • [ ] this doesn’t include the poems
  • [ ] some of the relevant code is still in the parent document

4.5.2 list the plays

The first—and only—thing we can say for sure is that Shakespeare did not organize his plays into any kind of hierarchy or taxonomy.

The plays, as a whole, are essentially unstructured and unordered.

The plays are a list. That is, they are flat. We don’t impose any structure on them “physically.”

Remember, the MIT site was made before stylesheets existed (let alone positioned layouts).

But we can treat the arrangement of the signs as a completely separate matter.

If you have room, they’ll be arranged in columns. If you don’t have room, they’ll look like a list.

Yes, we still have to choose a sequence.

But this is clear enough.

4.5.3 thinking

you have to choose

The greatest difficulty is choosing one way to present the plays. It’s not that there aren’t good options. It’s that you have to “bless” one by making it the first one that is seen.

But this isn’t print, right? One of the great advantages of new media is that you aren’t stuck with your decisions—even after delivery.

and?

From a document viewpoint, it’s simple enough: it’s just a list, a sort of table of contents.

Going back to the old MIT site, you already have a blurred line between the semantics and the presentation, since it uses a table—a table!—to present the “list” of plays in columns for easy viewing.

Indeed, a multi-column view is a convenient way to look at, select, and even understand the plays. But we’re drawing a finer line between “semantics” and “presentation.” Why? I mean, the web is a steaming pile of garbage anyway, right? Why not just do what the MIT site did and be pragmatic?

Well, these days, we have to bow to a different kind of pragmatism, and that is the reality of devices. We don’t know the size of the screen. So we can’t get attached to any one way of viewing things, anyway.

In the “space” view of things, our main interest becomes the physical arrangements.

4.5.4 implementation : layout

Arrangements of the play signs within the works area.

#the-plays-signs
	plain-list()
	position absolute
	top $playsHeadingHeight + $genresHeight
	left 0
	right 0
	height 100vh
@import colors
@import docking
@import paper
@import centering
@import pointing

$playSignHeight = 3em

// Variables for plays.
$comedies = TGV, Err, Shr, LLL, MND, TN, AYL, Ado, Wiv, MV, Tro, MM, AWW
$histories = '1H6', '2H6', '3H6', R3, R2, '1H4', '2H4', H5, Jn, H8
$tragedies = Tit, JC, Rom, Oth, Ham, Lr, Mac, Ant, Cor, Tim
$romances = Per, WT, Cym, Tmp

$longestGenreList = $comedies
$longestGenreListLength = length($longestGenreList)

<<play signs rules>>
stack_plays(plays, group = 0)
	for $play, $index in plays
		#play-{$play}-sign
			top $index * $playSignHeight
			z-index group * $longestGenreListLength + $index

stack_plays($histories, 0)
stack_plays($comedies, 1)
stack_plays($tragedies, 2)
stack_plays($romances, 3)
plays-block($plays, $also = '')
	$s = ''
	for $play, i in $plays
		$s += ',' if i > 0
		$s += '#play-' + $play + '-sign'
	$s += ',' + $also if $also
	{$s}
		{block}

The “play sign” is just used for positioning and sizing. By itself, it’s an invisible box.

.play-sign
	// These are positioned by id in groups.
	position absolute
	overflow hidden
	height $playSignHeight

.play-sign
.play-genre
	left 50%

Whereas the “play sign link” is the physical thing.

.play-sign-link
	display flex
	height 100%
	align-items center
	padding-left .25em
	overflow hidden

	// This is used mainly to demark the play signs, when they are adjacent.
	box-sizing border-box
	border-right 1px solid rgba(#111, .1)
	border-bottom @border-right

	background $paperColor

	+user_pointing_at()
		background $worksLightColor

The “play sign title” is an <i> whose job is to try to be readable.

@import responsive
.play-sign-title
	font-style normal                       // beat <i> default
	letter-spacing -.04em
	white-space nowrap
	<<play sign text rules>>

If the screen is large, the title can grow!

+wide-screen(55rem)
	font-size 125%
+wide-screen(60rem)
	font-size 133%
+wide-screen(65rem)
	font-size 150%

Rather than shrinking the font size for smaller screens, try other measures first: let it wrap to several lines and hyphenate, in which case it looks best centered horizontally.

+narrow-screen(55rem)
	white-space normal
	hyphens auto
	line-height .9
	left 0
	right 0
	text-align center
	max-height 100%
	padding 0 2px
	box-sizing border-box

But if the screen is really small, even that will not suffice.

+narrow-screen(50rem)
	font-size 80%
do_genres(
	$historiesWidth,
	$comediesWidth, $tragediesWidth,
	$romancesWidth)

	$historiesLeft = 0%
	$comediesLeft = $historiesLeft + $historiesWidth
	$tragediesLeft = $comediesLeft + $comediesWidth
	$romancesLeft = $tragediesLeft + $tragediesWidth

	+plays-block($histories, $also: '.play-genre.history')
		left $historiesLeft
		width $historiesWidth

	+plays-block($comedies, $also: '.play-genre.comedy')
		left $comediesLeft
		width $comediesWidth

	+plays-block($tragedies, $also: '.play-genre.tragedy')
		left $tragediesLeft
		width $tragediesWidth

	+plays-block($romances, $also: '.play-genre.romance')
		left $romancesLeft
		width $romancesWidth

This seems stupid, but I think the point was to support alternate arrangements, in which case this would be put under another selector.

For various reasons, we’d like the comedies to be centered. It just looks better: their titles are the longest, and frankly, they’re just the best of Shakespeare’s works overall.3 Plus, a little symmetry helps to anchor the image in your mind.

$poemsWidth = 20%
$ratio = 100% / (100% - $poemsWidth)
$com = 28% * $ratio
$hist = 17% * $ratio
$trag = 19% * $ratio
do_genres(
	$historiesWidth: $hist,
	$comediesWidth: $com,
	$tragediesWidth: $trag,
	$romancesWidth: 100% - ($com + $hist + $trag))

“The poems” heading stays more or less centered vertically (with respect to “the plays” heading), whether it’s on one line or two.

#the-poems
	right 50%

#the-poems-heading
	display flex
	align-items center
	height 5rem
	line-height .8

	@media (min-width 35rem)
		font-size 300%

	@media (max-width 25rem)
		font-size 150%

Footnotes:

1

“genre,” Online Etymology Dictionary http://etymonline.com/index.php?term=genre

2

“genus,” Online Etymology Dictionary http://etymonline.com/index.php?term=genus

3

Don’t take my word for it. Doctor Johnson unapologetically favors the comedies, too.

about willshake

Project “willshake” is an ongoing effort to bring the beauty and pleasure of Shakespeare to new media.

Please report problems on the issue tracker. For anything else, public@gavinpc.com

Willshake is an experiment in literate programming—not because it’s about literature, but because the program is written for a human audience.

Following is a visualization of the system. Each circle represents a document that is responsible for some part of the system. You can open the documents by touching the circles.

Starting with the project philosophy as a foundation, the layers are built up (or down, as it were): the programming system, the platform, the framework, the features, and so on. Everything that you see in the site is put there by these documents—even this message.

Again, this is an experiment. The documents contain a lot of “thinking out loud” and a lot of old thinking. The goal is not to make it perfect, but to maintain a reflective process that supports its own evolution.

graph of the program

about

Shakespeare

An edition of the plays and poems of Shakespeare.

the works