From f34da37f98e47bbde47c23072fbd8670ef4435d2 Mon Sep 17 00:00:00 2001
From: ezsh <ezsh.junk@gmail.com>
Date: Mon, 18 Feb 2019 08:36:37 +0100
Subject: [PATCH] Move tabs CSS into its own file

Tweego will put the CSS code into the header, endering the
CreateSimpleTabs widget unneeded.
---
 src/003-assets/CSS/tabs.css           | 51 ++++++++++++++++++++++
 src/facilities/farmyard/farmyard.tw   |  1 -
 src/facilities/nursery/nursery.tw     |  2 -
 src/uncategorized/arcade.tw           |  1 -
 src/uncategorized/brothel.tw          |  1 -
 src/uncategorized/cellblock.tw        |  1 -
 src/uncategorized/clinic.tw           |  1 -
 src/uncategorized/club.tw             |  1 -
 src/uncategorized/dairy.tw            |  1 -
 src/uncategorized/economics.tw        |  1 -
 src/uncategorized/headGirlSuite.tw    |  1 -
 src/uncategorized/main.tw             |  3 +-
 src/uncategorized/masterSuite.tw      |  1 -
 src/uncategorized/pit.tw              |  3 +-
 src/uncategorized/schoolroom.tw       |  1 -
 src/uncategorized/servantsQuarters.tw |  1 -
 src/uncategorized/spa.tw              |  1 -
 src/utility/miscWidgets.tw            | 61 +++------------------------
 18 files changed, 58 insertions(+), 75 deletions(-)
 create mode 100644 src/003-assets/CSS/tabs.css

diff --git a/src/003-assets/CSS/tabs.css b/src/003-assets/CSS/tabs.css
new file mode 100644
index 00000000000..1e9db3744c9
--- /dev/null
+++ b/src/003-assets/CSS/tabs.css
@@ -0,0 +1,51 @@
+div.tab {
+	overflow: hidden;
+	border: 1px solid #ccc;
+	background-color: transparent;
+}
+
+div.tab button {
+	background-color: inherit;
+	float: left;
+	border: none;
+	outline: none;
+	cursor: pointer;
+	padding: 14px 16px;
+	transition: 0.3s;
+	font-size: 19px;
+}
+
+div.tab button:hover {
+	background-color: #444;
+}
+
+div.tab button.active {
+	background-color: #777;
+}
+
+.tabcontent {
+	display: none;
+	padding: 6px 12px;
+	-webkit-animation: fadeEffect 1s;
+	animation: fadeEffect 1s;
+}
+
+@-webkit-keyframes fadeEffect {
+	from {
+		opacity: 0;
+	}
+
+	to {
+		opacity: 1;
+	}
+}
+
+@keyframes fadeEffect {
+	from {
+		opacity: 0;
+	}
+
+	to {
+		opacity: 1;
+	}
+}
diff --git a/src/facilities/farmyard/farmyard.tw b/src/facilities/farmyard/farmyard.tw
index 2e833adb8da..84c46326557 100644
--- a/src/facilities/farmyard/farmyard.tw
+++ b/src/facilities/farmyard/farmyard.tw
@@ -469,7 +469,6 @@ $farmyardNameCaps is an oasis of growth in the midst of the jungle of steel and
 <</if>>
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/facilities/nursery/nursery.tw b/src/facilities/nursery/nursery.tw
index f127a210b57..1e22165dcd5 100644
--- a/src/facilities/nursery/nursery.tw
+++ b/src/facilities/nursery/nursery.tw
@@ -126,7 +126,6 @@ $nurseryNameCaps
 
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
@@ -482,7 +481,6 @@ Target age for release: <<textbox "$targetAgeNursery" $targetAgeNursery "Nursery
 <<if $useSlaveSummaryTabs == 1>>
 	<<set _j = "Back", _k = "AC Dump", _l = "Main">>
 
-	<<CreateSimpleTabs>>
 	<body>
 
 	<div class="tab">
diff --git a/src/uncategorized/arcade.tw b/src/uncategorized/arcade.tw
index f1aa702f304..bdffa352370 100644
--- a/src/uncategorized/arcade.tw
+++ b/src/uncategorized/arcade.tw
@@ -132,7 +132,6 @@ $arcadeNameCaps
 
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/brothel.tw b/src/uncategorized/brothel.tw
index 415e56c6bd3..52d7ed3e934 100644
--- a/src/uncategorized/brothel.tw
+++ b/src/uncategorized/brothel.tw
@@ -213,7 +213,6 @@ Last week this
 
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/cellblock.tw b/src/uncategorized/cellblock.tw
index 1203af61554..a84de2a4ef5 100644
--- a/src/uncategorized/cellblock.tw
+++ b/src/uncategorized/cellblock.tw
@@ -120,7 +120,6 @@ $cellblockNameCaps
 
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/clinic.tw b/src/uncategorized/clinic.tw
index 3e5aeaa1e43..2d8fa676cdf 100644
--- a/src/uncategorized/clinic.tw
+++ b/src/uncategorized/clinic.tw
@@ -142,7 +142,6 @@ $clinicNameCaps
 
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/club.tw b/src/uncategorized/club.tw
index b68d1366a9a..176af0c1d34 100644
--- a/src/uncategorized/club.tw
+++ b/src/uncategorized/club.tw
@@ -257,7 +257,6 @@ $clubNameCaps
 
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/dairy.tw b/src/uncategorized/dairy.tw
index 9d92e0538c3..2d9a8bc9733 100644
--- a/src/uncategorized/dairy.tw
+++ b/src/uncategorized/dairy.tw
@@ -532,7 +532,6 @@ $dairyNameCaps
 <</if>>
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/economics.tw b/src/uncategorized/economics.tw
index 0ff50c41a7c..d4cad0118a6 100644
--- a/src/uncategorized/economics.tw
+++ b/src/uncategorized/economics.tw
@@ -53,7 +53,6 @@
 <</if>>
 
 <<else>>
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/headGirlSuite.tw b/src/uncategorized/headGirlSuite.tw
index 4239b5368b2..474c4d5e2a4 100644
--- a/src/uncategorized/headGirlSuite.tw
+++ b/src/uncategorized/headGirlSuite.tw
@@ -46,7 +46,6 @@
 <</if>>
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/main.tw b/src/uncategorized/main.tw
index 5a40ad3045d..fd47864c36e 100644
--- a/src/uncategorized/main.tw
+++ b/src/uncategorized/main.tw
@@ -103,7 +103,6 @@ __''MAIN MENU''__&nbsp;&nbsp;&nbsp;&nbsp;//[[Summary Options]]//
 	<</if>>
 	<<set _j = "Back", _k = "AS Dump", _l = "Main">>
 
-	<<CreateSimpleTabs>>
 	<body>
 
 	<div class="tab">
@@ -431,7 +430,7 @@ __''MAIN MENU''__&nbsp;&nbsp;&nbsp;&nbsp;//[[Summary Options]]//
 	<<else>>
 		<script>document.getElementById("tab all").click();</script>
 	<</if>>
-	
+
 	</body>
 	<<if $positionMainLinks <= 0>>
 		<br><<MainLinks>>
diff --git a/src/uncategorized/masterSuite.tw b/src/uncategorized/masterSuite.tw
index 8b5891a687f..b8289dc54a2 100644
--- a/src/uncategorized/masterSuite.tw
+++ b/src/uncategorized/masterSuite.tw
@@ -354,7 +354,6 @@ $masterSuiteNameCaps is furnished
 
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/pit.tw b/src/uncategorized/pit.tw
index c6fff6e30cd..a91ecfb7bfe 100644
--- a/src/uncategorized/pit.tw
+++ b/src/uncategorized/pit.tw
@@ -333,7 +333,6 @@ $pitNameCaps is clean and ready,
 <</if>>
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
@@ -360,7 +359,7 @@ $pitNameCaps is clean and ready,
 			<<showallAssignmentFilter>>
 			<<set $Flag = 0>>
 			<<include "Slave Summary">>
-			<<resetAssignmentFilter>>	
+			<<resetAssignmentFilter>>
 		<</if>>
 	</div>
 </div>
diff --git a/src/uncategorized/schoolroom.tw b/src/uncategorized/schoolroom.tw
index 527f6de315d..cb02ae48173 100644
--- a/src/uncategorized/schoolroom.tw
+++ b/src/uncategorized/schoolroom.tw
@@ -124,7 +124,6 @@ $schoolroomNameCaps is well-equipped, with wallscreens to display lessons. These
 <</if>>
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/servantsQuarters.tw b/src/uncategorized/servantsQuarters.tw
index 77325f89454..fd3f1420081 100644
--- a/src/uncategorized/servantsQuarters.tw
+++ b/src/uncategorized/servantsQuarters.tw
@@ -121,7 +121,6 @@ $servantsQuartersNameCaps
 
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/uncategorized/spa.tw b/src/uncategorized/spa.tw
index 58a0a1b897b..14f313d0e4e 100644
--- a/src/uncategorized/spa.tw
+++ b/src/uncategorized/spa.tw
@@ -128,7 +128,6 @@ $spaNameCaps
 
 <br><br>
 
-<<CreateSimpleTabs>>
 <body>
 
 <div class="tab">
diff --git a/src/utility/miscWidgets.tw b/src/utility/miscWidgets.tw
index 35b44478e7c..c8e91aa3231 100644
--- a/src/utility/miscWidgets.tw
+++ b/src/utility/miscWidgets.tw
@@ -979,59 +979,8 @@ This experience
 */
 <<widget "EventNameLink">><span id="name"><<print "[[SlaveFullName($args[0])|Long Slave Description][$nextLink = passage(), $eventDescription = 1]]">></span><</widget>>
 
-/*
- Call as <<EventNameDelink>>
- $args[0]: Slave.
-*/
-<<widget "EventNameDelink">><<replace "#name">><<= SlaveFullName($args[0])>><</replace>><</widget>>
-
-<<widget "CreateSimpleTabs">>
-
-	<head>
-	<style>
-
-	div.tab {
-		overflow: hidden;
-		border: 1px solid #ccc;
-		background-color: transparent;
-	}
-
-	div.tab button {
-		background-color: inherit;
-		float: left;
-		border: none;
-		outline: none;
-		cursor: pointer;
-		padding: 14px 16px;
-		transition: 0.3s;
-		font-size: 19px;
-	}
-
-	div.tab button:hover {
-		background-color: #444;
-	}
-
-	div.tab button.active {
-		background-color: #777;
-	}
-
-	.tabcontent {
-		display: none;
-		padding: 6px 12px;
-		-webkit-animation: fadeEffect 1s;
-		animation: fadeEffect 1s;
-	}
-
-	@-webkit-keyframes fadeEffect {
-		from {opacity: 0;}
-		to {opacity: 1;}
-	}
-
-	@keyframes fadeEffect {
-		from {opacity: 0;}
-		to {opacity: 1;}
-	}
-	</style>
-	</head>
-
-<</widget>>
+-/*
+- Call as <<EventNameDelink>>
+- $args[0]: Slave.
+-*/
+-<<widget "EventNameDelink">><<replace "#name">><<= SlaveFullName($args[0])>><</replace>><</widget>>
-- 
GitLab