mirror of
https://github.com/doublespeakgames/adarkroom.git
synced 2026-05-28 00:01:54 +08:00
92f7cf683e
Legends on boxes and lists are currently added via CSS and as stylesheets cannot be localised, translated strings rely upon an additional inline CSS. This commit inserts localised legends as "data-legend" attributes on proper elements, and then this attribute is shown by stylesheet rule content: attr(data-legend). No need of localisation script and more compact CSS rules.
60 lines
899 B
CSS
60 lines
899 B
CSS
#outfitting {
|
|
position: relative;
|
|
border: 1px solid black;
|
|
width: 200px;
|
|
margin-bottom: 20px;
|
|
padding: 5px 10px;
|
|
}
|
|
|
|
div#outfitting:before ,div#perks:before {
|
|
content: attr(data-legend);
|
|
position: absolute;
|
|
top: -13px;
|
|
background-color: white;
|
|
}
|
|
|
|
div.outfitRow {
|
|
position: relative;
|
|
cursor: default;
|
|
margin: 10px -30px 10px 0px;
|
|
}
|
|
|
|
div.outfitRow > .row_val {
|
|
padding-right: 30px;
|
|
-webkit-touch-callout: none;
|
|
-webkit-user-select: none;
|
|
-khtml-user-select: none;
|
|
-moz-user-select: none;
|
|
-ms-user-select: none;
|
|
user-select: none;
|
|
}
|
|
|
|
div.outfitRow .tooltip {
|
|
width: 150px;
|
|
}
|
|
|
|
div#bagspace {
|
|
background-color: white;
|
|
position: absolute;
|
|
top:-13px;
|
|
right: 10px;
|
|
}
|
|
|
|
div#perks {
|
|
position: absolute;
|
|
top: 0px;
|
|
right: 0px;
|
|
border: 1px solid black;
|
|
cursor: default;
|
|
padding: 5px 10px;
|
|
width: 200px;
|
|
}
|
|
|
|
div.perkRow {
|
|
position: relative;
|
|
}
|
|
|
|
div.perkRow .row_key {
|
|
float: none;
|
|
}
|