aboutsummaryrefslogtreecommitdiff
path: root/users/ryan/modules/simple-bar/simple-bar-source/lib/styles/components/missives.js
diff options
context:
space:
mode:
Diffstat (limited to 'users/ryan/modules/simple-bar/simple-bar-source/lib/styles/components/missives.js')
-rwxr-xr-xusers/ryan/modules/simple-bar/simple-bar-source/lib/styles/components/missives.js89
1 files changed, 89 insertions, 0 deletions
diff --git a/users/ryan/modules/simple-bar/simple-bar-source/lib/styles/components/missives.js b/users/ryan/modules/simple-bar/simple-bar-source/lib/styles/components/missives.js
new file mode 100755
index 0000000..18e7b17
--- /dev/null
+++ b/users/ryan/modules/simple-bar/simple-bar-source/lib/styles/components/missives.js
@@ -0,0 +1,89 @@
1// Styles for /lib/components/missives/{missive|missives}.jsx components
2export const missivesStyles = /* css */ `
3.missives {
4 position: absolute;
5 top: 0;
6 left: 0;
7 width: 100%;
8 height: 100%;
9 pointer-events: none;
10 overflow: hidden;
11}
12.missive {
13 --gradient-size: 100px;
14
15 position: absolute;
16 top: 0;
17 width: fit-content;
18 height: 100%;
19 display: flex;
20 align-items: center;
21 gap: 10px;
22 padding: 0 16px;
23 box-sizing: border-box;
24 background-color: var(--background);
25 pointer-events: auto;
26 transition: transform 160ms var(--transition-easing);
27}
28.missive::after {
29 content: "";
30 position: absolute;
31 top: 0;
32 height: 100%;
33 width: var(--gradient-size);
34 pointer-events: none;
35}
36.missive--left {
37 left: 0;
38 animation: left-missive-appearance 320ms var(--transition-easing);
39}
40@keyframes left-missive-appearance {
41 0% {
42 transform: translateX(-100%);
43 }
44}
45.missive--left::after {
46 left: 100%;
47 background: linear-gradient(to right, var(--background) 0%, transparent 100%);
48}
49.missive--right {
50 right: 0;
51 flex-direction: row-reverse;
52 animation: right-missive-appearance 320ms var(--transition-easing);
53}
54@keyframes right-missive-appearance {
55 0% {
56 transform: translateX(100%);
57 }
58}
59.missive--right::after {
60 right: 100%;
61 background: linear-gradient(to left, var(--background) 0%, transparent 100%);
62}
63.missive__text {
64 max-width: calc(100vw - var(--gradient-size));
65 overflow: hidden;
66}
67.missive__close {
68 width: 24px;
69 height: 24px;
70 display: flex;
71 align-items: center;
72 justify-content: center;
73 fill: var(--foreground);
74 background-color: transparent;
75 border: 0;
76 cursor: pointer;
77 user-select: none;
78 border-radius: var(--item-radius);
79 transition: box-shadow 160ms var(--transition-easing);
80}
81.missive__close:hover {
82 box-shadow: var(--light-shadow), var(--hover-ring);
83}
84.missive__close-icon {
85 flex: 0 0 10px;
86 width: 10px;
87 height: 10px;
88}
89`;