Jump to content

Template:Class figure/styles.css

From Wikisource
.wst-figure-wrapper {
	display: grid;
	align-items: center;
	justify-content: center;
	
	/* center figure */
	max-width: max-content;
	margin-left: auto;
	margin-right: auto;
}

.wst-figure-image { /* center image */
	display: flex;
	justify-content: center;
}
.wst-figure-image img {
	max-width: 100%;
	height: auto;
}

.wst-figure-source {
	text-align: right;
}

.wst-figure-caption {
	text-align: center;
}

.wst-figure-number-separator::after {
	content: "—";
}


/******************************************************************************
			Highlight when linked to, modeled after {{ph}}
******************************************************************************/
.wst-figure-wrapper:target {
    background-color: rgba(100, 149, 237, 0.1);
    color: inherit;
    outline: 1px solid cornflowerblue;
}

/******************************************************************************
								float
******************************************************************************/
.wst-figure-wrapper.float-left,
.wst-figure-wrapper.float-right {
	margin: 1em;
}
.wst-figure-wrapper.float-left {
	float: left;
	clear: left;
	margin-left: 0em;
}
.wst-figure-wrapper.float-right {
	float: right;
	clear: right;
	margin-right: 0em;
}