-
Notifications
You must be signed in to change notification settings - Fork 0
/
ken-sample.html
128 lines (110 loc) · 3.2 KB
/
ken-sample.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Välkommen till Nikita Hair</title>
<style>
* {
margin: 0;
padding: 0;
}
body,
html {
height: 100%;
}
/* Rotate the entire page content */
.rotated-container {
position: absolute;
width: 100vh; /* Switch width and height due to rotation */
height: 100vw;
top: 50%;
left: 50%;
transform: translate(-50%, -50%) rotate(90deg); /* Rotate the page 90 degrees */
transform-origin: center;
background-color: black;
overflow: hidden;
}
.container {
position: relative;
width: 100vh;
height: 100vw;
overflow: hidden;
}
.image {
position: absolute;
width: 120vh;
/* Make the image larger than the viewport */
height: 120vw;
/* Keep aspect ratio similar to avoid stretching */
top: -20vh;
/* Center the image vertically within the viewport */
left: 0vh;
/* Center the image horizontally */
animation: pan 20s infinite ease-in-out;
}
iframe {
position: absolute;
width: 100%;
height: 100%;
top: 0;
left: 0;
border: 0;
}
.scrolling-text-container {
position: fixed;
top: 0;
width: 100vw;
height: 2em;
padding: 1em;
overflow: hidden;
background-color: #00000080;
/* Optional: to highlight the text background */
}
.scrolling-text {
position: absolute;
white-space: nowrap;
color: white;
font-size: 24px;
animation: scroll 10s linear infinite;
margin-top: 1px;
font-style: system-ui;
}
@keyframes pan {
0% {
transform: translate(0, 0);
}
40% {
transform: translate(-20vh, 10vw);
/* Move the image to pan across it */
}
70% {
transform: translate(-20vh, 0vw);
/* Move the image to pan across it */
}
100% {
transform: translate(0, 0);
}
}
@keyframes scroll {
0% {
transform: translateX(240%);
}
100% {
transform: translateX(-100%);
}
}
</style>
</head>
<body>
<div class="rotated-container">
<div class="container">
<img src="Nikita-Hair-frisor.jpg" alt="Panning Image" class="image">
</div>
<iframe title="timer" src="https://shoppaab.github.io/raise-demo/index.html"></iframe>
<div class="scrolling-text-container">
<div class="scrolling-text">Vi har tid för dig alldeles strax. Välkommen in!</div>
</div>
</div>
</body>
</html>