- {{structure.Structure}}
+
+
{{structure.Structure}}
+
Furniture
diff --git a/temporary-sign/temporary-sign.css b/temporary-sign/temporary-sign.css
index 70f331d..cbd6ac7 100644
--- a/temporary-sign/temporary-sign.css
+++ b/temporary-sign/temporary-sign.css
@@ -22,10 +22,34 @@ body {
height: 700px;
padding: 4px;
position: relative;
+ background: #ffffff url(background.png) center center/cover no-repeat;
+ display: flex;
+ flex-direction: column;
+}
+
+.name {
+ display: flex;
+ justify-content: center;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ flex-grow: 1;
+ padding: 20px;
+ flex-direction: column;
+ align-items: center;
+}
+
+.furniture {
+ bottom: 0;
+ left: 0;
+ justify-self: flex-end;
+ margin-right: 275px;
+ padding: 0 20px 10px 20px;
+ background: rgba(255, 255, 255, 0.8);
}
h1 {
text-align: center;
+ margin: 0px;
}
h2 {
@@ -70,13 +94,7 @@ tbody tr:nth-child(odd) {
background-color: #f0f0f0;
}
-.furniture {
- position: absolute;
- bottom: 0px;
- left: 0px;
- right: 0px;
- padding: 4px 10px;
-}
+
.qrcode img {
display: block;
diff --git a/temporary-sign/temporary-sign.ts b/temporary-sign/temporary-sign.ts
index 43a458e..09364cd 100644
--- a/temporary-sign/temporary-sign.ts
+++ b/temporary-sign/temporary-sign.ts
@@ -51,7 +51,23 @@ const normalizeBetweenTwoRanges = (val, minVal, maxVal, newMin, newMax) => {
function scaleFont(words) {
- return normalizeBetweenTwoRanges(words.length, 0, 100, 256, 10)
+ if (words.length < 10) {
+ return 256
+ }
+
+ if (words.length < 20) {
+ return 170
+ }
+
+ if (words.length < 30) {
+ return 150
+ }
+
+ if (words.length < 40) {
+ return 125
+ }
+
+ return normalizeBetweenTwoRanges(words.length, 0, 80, 256, 100)
}
function tweakUrl(url) {