From 9ec8a40752cbbbbdb336d8fbe69d6817f98718eb Mon Sep 17 00:00:00 2001 From: Joe Fredette Date: Wed, 6 Jul 2016 08:44:21 -0400 Subject: [PATCH] [Godbound] CSS -> SCSS introduces SCSS to help clean up the CSS and allow easier development --- Godbound/.gitignore | 2 + Godbound/Godbound.css | 367 +++++++++++++--------------------- Godbound/Godbound.scss | 1 + Godbound/Makefile | 3 + Godbound/css/Character.scss | 387 ++++++++++++++++++++++++++++++++++++ 5 files changed, 528 insertions(+), 232 deletions(-) create mode 100644 Godbound/.gitignore create mode 100644 Godbound/Godbound.scss create mode 100644 Godbound/Makefile create mode 100644 Godbound/css/Character.scss diff --git a/Godbound/.gitignore b/Godbound/.gitignore new file mode 100644 index 0000000000..e34c232831 --- /dev/null +++ b/Godbound/.gitignore @@ -0,0 +1,2 @@ +*.css.map +.sass-cache/ diff --git a/Godbound/Godbound.css b/Godbound/Godbound.css index f6200dc5b6..27210bca17 100644 --- a/Godbound/Godbound.css +++ b/Godbound/Godbound.css @@ -1,8 +1,45 @@ -.sheet-container { - font-size: 0.75em; -} +button[type=roll].sheet-blank-roll-button { + width: 3.25em; + height: 2em; + margin-left: 0.75em; } + button[type=roll].sheet-blank-roll-button::before { + content: ""; } + button[type=roll].sheet-blank-roll-button input { + position: relative; + width: 2.5em; + height: 1.25em; + top: -20px; } -.sheet-container::after { +th { + text-align: center; } + +textarea { + height: 4em; + max-width: 70%; + min-width: 70%; } + +input[type=number] { + text-align: right; } + +.sheet-input .sheet-saves { + height: 1.25em; + width: 2.5em; + margin: 0; + padding: 0; + margin-left: 0.75em; } +.sheet-input .sheet-rollable-value.sheet-saves { + margin-left: 0; } + +.sheet-column { + width: 30%; + float: left; + display: inline-block; + margin-left: 0; + padding: 1.25em; } + +.sheet-container { + font-size: 0.75em; } + .sheet-container::after { content: ""; top: 45px; left: 0; @@ -12,97 +49,41 @@ z-index: -1; height: 200%; background: url("http://i.imgur.com/BLb0XMU.jpg"); - background-size: 100% 100%; -} - -button[type=roll].sheet-blank-roll-button::before { - content: ""; -} - -button[type=roll].sheet-blank-roll-button { - width: 3.25em; - height: 2em; - margin-left: 0.75em; -} - -button[type=roll].sheet-blank-roll-button > input { - position: relative; - width: 2.5em; - height: 1.25em; - top: -20px; -} - -.sheet-input.sheet-saves { - height: 1.25em; - width: 2.5em; - margin: 0; - padding: 0; - margin-left: 0.75em; -} - -.sheet-input.sheet-rollable-value.sheet-saves { - margin-left: 0; -} - -.sheet-column { - width: 30%; - float: left; - display: inline-block; - margin-left: 0; - padding: 1.25em; -} - -.repitem .sheet-table-row { - text-align: justify; -} + background-size: 100% 100%; } .sheet-stats, .sheet-saves { - width: 100%; -} + width: 100%; } .sheet-field-title { width: 20%; padding: 0; padding-bottom: 10px; - margin: 0; -} + margin: 0; } .sheet-armor .sheet-input { width: 70%; padding: 0; - margin: 0 0 10px 10px; -} + margin: 0 0 10px 10px; } .sheet-small-title-label { font-style: italic; font-weight: normal; - display: inline-block; -} + display: inline-block; } .sheet-armor-ac .sheet-input { - width: 10%; -} + width: 10%; } -.sheet-armor-type { - clear: both; -} - -.sheet-armor { - clear: both; -} +.sheet-armor-type, .sheet-armor, .sheet-attributes { + clear: both; } .sheet-weapons { clear: both; - margin-top: 1em; -} - -.sheet-weapons .sheet-weapons-list { - margin-top: 1em; -} + margin-top: 1em; } + .sheet-weapons .sheet-weapons-list { + margin-top: 1em; } .sheet-fray-die { - width: 30px; -} + width: 30px; } .sheet-title-label { clear: both; @@ -111,282 +92,204 @@ button[type=roll].sheet-blank-roll-button > input { border-bottom: 1px solid black; text-align: center; margin-top: 0.5em; - padding: 0; -} - -.sheet-attributes { - clear: both; -} + padding: 0; } .sheet-attributes .sheet-table-attributes { text-align: right; - width: 100%; -} - -.sheet-attributes .sheet-table-attributes > td{ - text-align: center; -} + width: 100%; } + .sheet-attributes .sheet-table-attributes .sheet-table-attributes > td { + text-align: center; } .sheet-saves { - margin-top: 2em; -} + margin-top: 2em; } .sheet-saves-section table.sheet-table-saves { text-align: right; width: 100%; - margin-left: -4em; -} + margin-left: -4em; } .sheet-button .sheet-input { border: none; padding: 0; - margin: 0; -} + margin: 0; } .sheet-info .sheet-input { width: 70%; float: left; padding: 0; - margin: 0 0 10px 10px; -} + margin: 0 0 10px 10px; } .sheet-facts .sheet-input { width: 70%; padding: 0; margin: 0; margin-bottom: 10px; - float: right; -} + float: right; } .sheet-field-title { clear: both; width: 25%; float: left; text-align: right; - padding-bottom: 10px; -} + padding-bottom: 10px; } .sheet-table-field-title { width: 10%; font-style: italic; padding-right: 0.5em; text-align: right; - text-transform: uppercase; -} + text-transform: uppercase; } .sheet-table-header { padding: 0 5%; - text-align: center; -} + text-align: center; } .sheet-table-cell { - display: table-cell; -} + display: table-cell; } .sheet-table-row { display: inline-block; width: 100%; margin: 0; - padding: 0; -} + padding: 0; } .sheet-weapon-name { - width: 5em; -} - + width: 5em; } .sheet-center-column { border-left: 1px solid black; - border-right: 1px solid black; -} - + border-right: 1px solid black; } .sheet-weapon { - width: 100%; -} + width: 100%; } .sheet-weapon-name { display: inline-block; border-top: 1px; border-top-style: dashed; padding-top: 10px; - width: 100%; -} - -.sheet-input.sheet-weapon-name { - width: 100%; - float: left; - margin: 0; - padding: 0; - border: none; - font-style: italic; -} + width: 100%; } + .sheet-weapon-name.sheet-input { + width: 100%; + float: left; + margin: 0; + padding: 0; + border: none; + font-style: italic; } .sheet-weapon-info .sheet-weapon-info-element { float: left; margin-right: 5%; padding: 0; - width: 25%; -} - -.sheet-weapon-info-element.sheet-weapon-info-roll { - float: right; - width: 25px; - margin: 0; - padding: 0; -} + width: 25%; } + .sheet-weapon-info .sheet-weapon-info-element.sheet-weapon-info-roll { + float: right; + width: 25px; + margin: 0; + padding: 0; } .sheet-field-label.sheet-weapons-ab { clear: both; float: left; width: 50%; margin: 0; - padding: 5px 0 0 0; -} + padding: 5px 0 0 0; } -.sheet-table-weapons .repcontrol { - border-top: 1px dashed black; - padding-top: 10px; - clear: both; -} - -.repcontrol { - clear: both; -} - -.sheet-dropdown { - width: 100%; -} +.sheet-dropdown, .sheet-damage-chart { + width: 100%; } .sheet-weapon-info-element.sheet-input { - width: 100% !important; -} + width: 100% !important; } .sheet-table-weapons .sheet-input { width: 100% !important; - text-align: center; -} + text-align: center; } .sheet-table-weapons .sheet-table-header { - text-align: justify; -} + text-align: justify; } .sheet-info .sheet-field-title { - text-align: right; -} - + text-align: right; } .sheet-info .sheet-hp span .sheet-input { - text-align: center; -} + text-align: center; } .sheet-fray { width: 100%; margin: 0; padding: 0; float: left; - text-align: center; -} - -.sheet-damage-chart { - width: 100%; -} + text-align: center; } .sheet-col.sheet-fray-die { width: 33% !important; margin: 0 !important; - float: left; -} + float: left; } +.sheet-col.sheet-damage-chart { + width: 60% !important; + float: right; } .sheet-armor-saving-throw-penalty-choice { width: 20%; display: inline-block; margin: 0; - padding: 0 5px; -} - -.sheet-armor-saving-throw-penalty-choice .sheet-saving-throw-penalty-element { - width: 100%; - margin: 0; - padding: 0 12px; -} - -.sheet-col.sheet-damage-chart { - width: 60% !important; - float: right; -} + padding: 0 5px; } + .sheet-armor-saving-throw-penalty-choice .sheet-saving-throw-penalty-element { + width: 100%; + margin: 0; + padding: 0 12px; } .sheet-power-name { - width:63%; - float:left; -} + width: 63%; + float: left; } .sheet-power-cost { - float: left; -} + float: left; } .sheet-power-effort { - width:15%; + width: 15%; float: left; - padding-bottom:5px; -} + padding-bottom: 5px; } -.sheet-table-header.sheet-power-name { +.sheet-table-header .sheet-power-name { margin: 0; padding: 0; - text-align: left; -} - -.sheet-table-header.sheet-power-effort { + text-align: left; } +.sheet-table-header .sheet-power-effort { margin: 0; padding: 0; - text-align: right; -} + text-align: right; } .sheet-resources-table { margin: 0; - width: 70%; -} - -input[type=number] { - text-align: right; -} + width: 70%; } .sheet-values { float: left; - margin-left: 10px; -} - -.sheet-values .sheet-input { - margin: 0; - width: 40px; -} - -.sheet-values .sheet-min { - float: left; -} - -.sheet-values .sheet-max { - float: right; -} - -.sheet-values .sheet-separator { - margin: 0 10px; -} - -th { - text-align: center; -} - -textarea { - height: 4em; - max-width: 70%; - min-width: 70%; -} - + margin-left: 10px; } + .sheet-values .sheet-input { + margin: 0; + width: 40px; } + .sheet-values .sheet-min { + float: left; } + .sheet-values .sheet-max { + float: right; } + .sheet-values .sheet-separator { + margin: 0 10px; } .sheet-version-container { clear: both; width: 100%; - border-top: 1px solid black; -} + border-top: 1px solid black; } +.repitem .sheet-table-row { + text-align: justify; } + +.sheet-table-weapons .repcontrol { + border-top: 1px dashed black; + padding-top: 10px; + clear: both; } + +.repcontrol { + clear: both; } + +/*# sourceMappingURL=Godbound.css.map */ diff --git a/Godbound/Godbound.scss b/Godbound/Godbound.scss new file mode 100644 index 0000000000..6dedefa273 --- /dev/null +++ b/Godbound/Godbound.scss @@ -0,0 +1 @@ +@import "css/Character" diff --git a/Godbound/Makefile b/Godbound/Makefile new file mode 100644 index 0000000000..ae94d07804 --- /dev/null +++ b/Godbound/Makefile @@ -0,0 +1,3 @@ +.PHONY: css +css: + scss Godbound.scss Godbound.css diff --git a/Godbound/css/Character.scss b/Godbound/css/Character.scss new file mode 100644 index 0000000000..cf3947db10 --- /dev/null +++ b/Godbound/css/Character.scss @@ -0,0 +1,387 @@ + +button[type=roll].sheet-blank-roll-button { + width: 3.25em; + height: 2em; + margin-left: 0.75em; + + &::before { + content: ""; + } + + input { + position: relative; + width: 2.5em; + height: 1.25em; + top: -20px; + } +} + +th { + text-align: center; +} + +textarea { + height: 4em; + max-width: 70%; + min-width: 70%; +} + +input[type=number] { + text-align: right; +} + +.sheet-input { + .sheet-saves { + height: 1.25em; + width: 2.5em; + margin: 0; + padding: 0; + margin-left: 0.75em; + } + + .sheet-rollable-value.sheet-saves { + margin-left: 0; + } +} + +.sheet-column { + width: 30%; + float: left; + display: inline-block; + margin-left: 0; + padding: 1.25em; +} + +.sheet-container { + font-size: 0.75em; + + &::after { + content: ""; + top: 45px; + left: 0; + bottom: 0; + right: 0; + position: absolute; + z-index: -1; + height: 200%; + background: url("http://i.imgur.com/BLb0XMU.jpg"); + background-size: 100% 100%; + } +} + +.sheet-stats, .sheet-saves { + width: 100%; +} + +.sheet-field-title { + width: 20%; + padding: 0; + padding-bottom: 10px; + margin: 0; +} + +.sheet-armor .sheet-input { + width: 70%; + padding: 0; + margin: 0 0 10px 10px; +} + +.sheet-small-title-label { + font-style: italic; + font-weight: normal; + display: inline-block; +} + +.sheet-armor-ac .sheet-input { + width: 10%; +} + +.sheet-armor-type, .sheet-armor, .sheet-attributes { + clear: both; +} + +.sheet-weapons { + clear: both; + margin-top: 1em; + + .sheet-weapons-list { + margin-top: 1em; + } +} + +.sheet-fray-die { + width: 30px; +} + +.sheet-title-label { + clear: both; + text-transform: uppercase; + font-weight: bold; + border-bottom: 1px solid black; + text-align: center; + margin-top: 0.5em; + padding: 0; +} + +.sheet-attributes { + .sheet-table-attributes { + text-align: right; + width: 100%; + + .sheet-table-attributes > td{ + text-align: center; + } + } +} + +.sheet-saves { + margin-top: 2em; +} + +.sheet-saves-section table.sheet-table-saves { + text-align: right; + width: 100%; + margin-left: -4em; +} + +.sheet-button .sheet-input { + border: none; + padding: 0; + margin: 0; +} + +.sheet-info .sheet-input { + width: 70%; + float: left; + padding: 0; + margin: 0 0 10px 10px; +} + +.sheet-facts .sheet-input { + width: 70%; + padding: 0; + margin: 0; + margin-bottom: 10px; + float: right; +} + +.sheet-field-title { + clear: both; + width: 25%; + float: left; + text-align: right; + padding-bottom: 10px; +} + +.sheet-table-field-title { + width: 10%; + font-style: italic; + padding-right: 0.5em; + text-align: right; + text-transform: uppercase; +} + +.sheet-table-header { + padding: 0 5%; + text-align: center; +} + +.sheet-table-cell { + display: table-cell; +} + +.sheet-table-row { + display: inline-block; + width: 100%; + margin: 0; + padding: 0; +} + +.sheet-weapon-name { + width: 5em; +} + +.sheet-center-column { + border-left: 1px solid black; + border-right: 1px solid black; +} + +.sheet-weapon { + width: 100%; +} + +.sheet-weapon-name { + display: inline-block; + border-top: 1px; + border-top-style: dashed; + padding-top: 10px; + width: 100%; + + &.sheet-input { + width: 100%; + float: left; + margin: 0; + padding: 0; + border: none; + font-style: italic; + } +} + +.sheet-weapon-info .sheet-weapon-info-element { + float: left; + margin-right: 5%; + padding: 0; + width: 25%; + + &.sheet-weapon-info-roll { + float: right; + width: 25px; + margin: 0; + padding: 0; + } +} + +.sheet-field-label.sheet-weapons-ab { + clear: both; + float: left; + width: 50%; + margin: 0; + padding: 5px 0 0 0; +} + +.sheet-dropdown, .sheet-damage-chart { + width: 100%; +} + +.sheet-weapon-info-element.sheet-input { + width: 100% !important; +} + +.sheet-table-weapons .sheet-input { + width: 100% !important; + text-align: center; +} + +.sheet-table-weapons .sheet-table-header { + text-align: justify; +} + +.sheet-info { + .sheet-field-title { + text-align: right; + } + + .sheet-hp span .sheet-input { + text-align: center; + } +} + +.sheet-fray { + width: 100%; + margin: 0; + padding: 0; + float: left; + text-align: center; +} + +.sheet-col { + &.sheet-fray-die { + width: 33% !important; + margin: 0 !important; + float: left; + } + + &.sheet-damage-chart { + width: 60% !important; + float: right; + } +} + +.sheet-armor-saving-throw-penalty-choice { + width: 20%; + display: inline-block; + margin: 0; + padding: 0 5px; + + .sheet-saving-throw-penalty-element { + width: 100%; + margin: 0; + padding: 0 12px; + } +} + +.sheet-power-name { + width:63%; + float:left; +} + +.sheet-power-cost { + float: left; +} + +.sheet-power-effort { + width:15%; + float: left; + padding-bottom:5px; +} + +.sheet-table-header { + .sheet-power-name { + margin: 0; + padding: 0; + text-align: left; + } + + .sheet-power-effort { + margin: 0; + padding: 0; + text-align: right; + } +} + +.sheet-resources-table { + margin: 0; + width: 70%; +} + +.sheet-values { + float: left; + margin-left: 10px; + + .sheet-input { + margin: 0; + width: 40px; + } + + .sheet-min { + float: left; + } + + .sheet-max { + float: right; + } + + .sheet-separator { + margin: 0 10px; + } +} + +.sheet-version-container { + clear: both; + width: 100%; + border-top: 1px solid black; +} + +.repitem .sheet-table-row { + text-align: justify; +} + +.sheet-table-weapons .repcontrol { + border-top: 1px dashed black; + padding-top: 10px; + clear: both; +} + +.repcontrol { + clear: both; +}