cortico-world-agent-speed 0.2.0 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +64 -0
- package/LICENSE +0 -14
- package/README.md +29 -11
- package/THIRD_PARTY_NOTICES.md +69 -0
- package/activity.d.ts +15 -0
- package/activity.js +88 -3
- package/describe.json +806 -0
- package/dist/webui.css +2 -0
- package/dist/webui.css.map +7 -0
- package/dist/webui.js +2 -0
- package/dist/webui.js.map +7 -0
- package/host/app-store.cjs +68 -0
- package/host/cursor.cjs +67 -0
- package/host/electron-main.cjs +666 -0
- package/host/input-shape.cjs +63 -0
- package/host/mouse-lease.cjs +77 -0
- package/host/overlay.cjs +139 -0
- package/host/portrait.cjs +52 -0
- package/host/preload.cjs +60 -14
- package/host/renderer-gone.cjs +24 -0
- package/host/windows.cjs +251 -0
- package/package.json +27 -7
- package/scripts/build-webui.mjs +40 -0
- package/scripts/speech-bank/build.py +166 -0
- package/scripts/speech-bank/dicts.py +76 -0
- package/src/ENV_PROMPT.en.md +51 -0
- package/src/ENV_PROMPT.md +51 -0
- package/src/asr/address.ts +25 -0
- package/src/asr/hotkey.ts +335 -0
- package/src/asr/result.ts +51 -0
- package/src/asr/segmenter.ts +269 -0
- package/src/asr/sherpa.ts +280 -0
- package/src/asr/simplify.ts +38 -0
- package/src/asr/system-recognizer.ts +292 -0
- package/src/asr/system-sapi.ps1 +173 -0
- package/src/asr/transcription-api.ts +176 -0
- package/src/chat.ts +212 -0
- package/src/config.ts +481 -0
- package/src/cua/ENV_PROMPT.en.md +29 -0
- package/src/cua/ENV_PROMPT.md +29 -0
- package/src/cua/config.ts +88 -0
- package/src/cua/cua.ts +712 -0
- package/src/cua/engine/darwin.ts +410 -0
- package/src/cua/engine/display.ts +55 -0
- package/src/cua/engine/fail.ts +15 -0
- package/src/cua/engine/foreground.ts +8 -0
- package/src/cua/engine/image.ts +57 -0
- package/src/cua/engine/keys.ts +70 -0
- package/src/cua/engine/linux-keys.ts +29 -0
- package/src/cua/engine/linux.ts +343 -0
- package/src/cua/engine/mac-keys.ts +57 -0
- package/src/cua/engine/user-activity.ts +54 -0
- package/src/cua/engine/wait-idle.ts +31 -0
- package/src/cua/engine/win32.ts +299 -0
- package/src/cua/engine-child.ts +274 -0
- package/src/cua/engine-ipc.ts +140 -0
- package/src/cua/i18n/de.ts +53 -0
- package/src/cua/i18n/en.ts +63 -0
- package/src/cua/i18n/es-419.ts +53 -0
- package/src/cua/i18n/fr.ts +53 -0
- package/src/cua/i18n/index.ts +26 -0
- package/src/cua/i18n/it.ts +53 -0
- package/src/cua/i18n/ja.ts +53 -0
- package/src/cua/i18n/ko.ts +53 -0
- package/src/cua/i18n/pt-BR.ts +53 -0
- package/src/cua/i18n/ru.ts +59 -0
- package/src/cua/i18n/zh-Hant.ts +53 -0
- package/src/cua/i18n/zh.ts +59 -0
- package/src/cua/model-text.ts +252 -0
- package/src/cua/terminal.ts +31 -0
- package/src/cua/tools.ts +153 -0
- package/src/definition.ts +146 -0
- package/src/host-reason.ts +32 -0
- package/src/i18n/de.ts +409 -0
- package/src/i18n/en.ts +443 -0
- package/src/i18n/es-419.ts +409 -0
- package/src/i18n/fr.ts +409 -0
- package/src/i18n/index.ts +56 -0
- package/src/i18n/it.ts +409 -0
- package/src/i18n/ja.ts +409 -0
- package/src/i18n/ko.ts +409 -0
- package/src/i18n/pt-BR.ts +409 -0
- package/src/i18n/ru.ts +415 -0
- package/src/i18n/zh-Hant.ts +409 -0
- package/src/i18n/zh.ts +440 -0
- package/src/index.ts +15 -0
- package/src/model-text.ts +344 -0
- package/src/moves.ts +101 -0
- package/src/pack-import.ts +361 -0
- package/src/packs.ts +449 -0
- package/src/runtime/download.ts +29 -0
- package/src/runtime/store.ts +293 -0
- package/src/script.ts +202 -0
- package/src/self.ts +247 -0
- package/src/server.ts +479 -0
- package/src/speech/data/CMUDICT-LICENSE +33 -0
- package/src/speech/data/IPADIC-COPYING +71 -0
- package/src/speech/data/UNICODE-LICENSE +39 -0
- package/src/speech/data/en.tsv.gz +0 -0
- package/src/speech/data/ja-ipadic.tsv.gz +0 -0
- package/src/speech/data/ja-unihan.tsv.gz +0 -0
- package/src/speech/data/zh.json +1 -0
- package/src/speech/index.ts +204 -0
- package/src/speech/ipa.ts +83 -0
- package/src/speech/japanese.ts +105 -0
- package/src/speech/jukujikun.ts +22 -0
- package/src/speech/korean.ts +35 -0
- package/src/speech/lang.ts +151 -0
- package/src/speech/rules.ts +72 -0
- package/src/speech/syllable.ts +76 -0
- package/src/status.ts +164 -0
- package/src/tools.ts +110 -0
- package/src/webui/api-rows.css +2 -0
- package/src/webui/api-rows.ts +44 -0
- package/src/webui/client.ts +451 -0
- package/src/webui/dress-dialog.css +14 -0
- package/src/webui/dress-dialog.ts +117 -0
- package/src/webui/dress-panel.ts +160 -0
- package/src/webui/key-capture.ts +60 -0
- package/src/webui/shared/modal.css +13 -0
- package/src/webui/shared/modal.ts +77 -0
- package/src/webui/shared/problem.css +15 -0
- package/src/webui/shared/problem.ts +217 -0
- package/src/webui/shared/strings.ts +5 -0
- package/src/webui/style.css +50 -0
- package/src/window-host.ts +116 -0
- package/src/world.ts +2926 -0
- package/web/activity-motion.js +117 -0
- package/web/appearance.js +60 -0
- package/web/body-host.js +257 -0
- package/web/coo/coo.js +384 -0
- package/web/coo/figure.js +15 -0
- package/web/coo/figure.json +1224 -0
- package/web/dist/dress-dialog.css +1 -0
- package/web/dist/dress-dialog.js +1 -0
- package/web/drag-row.js +49 -0
- package/web/drag.js +149 -0
- package/web/dress.css +170 -0
- package/web/dress.html +37 -0
- package/web/dress.js +786 -0
- package/web/figure-frame.html +16 -0
- package/web/figure-frame.js +128 -0
- package/web/frame-loop.js +55 -0
- package/web/hints.js +77 -0
- package/web/i18n/de.js +170 -0
- package/web/i18n/en.js +177 -0
- package/web/i18n/es-419.js +170 -0
- package/web/i18n/fr.js +170 -0
- package/web/i18n/it.js +170 -0
- package/web/i18n/ja.js +170 -0
- package/web/i18n/ko.js +170 -0
- package/web/i18n/pt-BR.js +170 -0
- package/web/i18n/ru.js +170 -0
- package/web/i18n/zh-Hant.js +170 -0
- package/web/i18n/zh.js +175 -0
- package/web/i18n.js +54 -0
- package/{renderer/vendor → web}/kit/body.js +31 -58
- package/web/looks.js +70 -0
- package/web/mic-worklet.js +36 -0
- package/web/mic.js +117 -0
- package/web/motion-frames.js +80 -0
- package/web/motion-level.js +40 -0
- package/web/new-year-2027.svg +238 -0
- package/web/overlay.html +16 -0
- package/web/overlay.js +100 -0
- package/web/pet-app.js +3000 -0
- package/web/pet.css +642 -0
- package/web/pet.html +21 -0
- package/web/scale-slider.js +259 -0
- package/web/show-hide.js +49 -0
- package/web/sound.js +245 -0
- package/web/speech/zh.json +1 -0
- package/web/speech/zh.ogg +0 -0
- package/web/speech.js +197 -0
- package/web/stage.js +160 -0
- package/web/swap-motion.js +119 -0
- package/web/ui.js +195 -0
- package/host/launch.js +0 -187
- package/host/library.cjs +0 -638
- package/host/main.cjs +0 -389
- package/index.js +0 -93
- package/renderer/index.html +0 -22
- package/renderer/pet-sandbox.html +0 -11
- package/renderer/pet.css +0 -38
- package/renderer/pet.js +0 -251
- package/renderer/vendor/activity-motion.js +0 -101
- package/renderer/vendor/figure-frame.js +0 -115
- package/renderer/vendor/pack.css +0 -2
- /package/{renderer/vendor → web}/kit/rig.js +0 -0
package/web/pet.css
ADDED
|
@@ -0,0 +1,642 @@
|
|
|
1
|
+
:root{
|
|
2
|
+
/* animation durations: colors and hovers, things appearing, larger moves */
|
|
3
|
+
--motion-fast:150ms; --motion-base:200ms; --motion-slow:280ms;
|
|
4
|
+
/* animation curves: a pop that overshoots, a softer one, and controls sliding back beside the body */
|
|
5
|
+
--motion-pop:cubic-bezier(.3,1.5,.5,1); --motion-pop-soft:cubic-bezier(.3,1.4,.5,1); --motion-return:cubic-bezier(.2,.7,.3,1);
|
|
6
|
+
/* the leaving animations pet-app.js and hints.js wait for before they hide the element */
|
|
7
|
+
--pop-out:160ms; --wheel-out:140ms; --slider-out:140ms; --return-time:260ms; --hint-out:120ms;
|
|
8
|
+
--bg:#F3F2F6; --surface:#FFFFFF; --text:#1B1626; --muted:#6A6577; --line:#E2DFE8;
|
|
9
|
+
--accent:#00A870;
|
|
10
|
+
--skin-ink:#1B1626; --skin-eye:#00A870;
|
|
11
|
+
--wall:#E8E6EE; --dot:#CFCBD9; --shadow:rgba(27,22,38,.12);
|
|
12
|
+
--sheen-top:rgba(255,255,255,.6); --sheen-bottom:rgba(27,22,38,.035);
|
|
13
|
+
--said-bg:#E6E9E7; --said-ink:#1F2221;
|
|
14
|
+
--blush:#FF8FA8; --tear:#5AAEF0; --anger:#E5484D; --heart:#F0567A; --dust:#A39DB0;
|
|
15
|
+
/* paused, as the settings window's rail shows it */
|
|
16
|
+
--warn:#96743B;
|
|
17
|
+
}
|
|
18
|
+
@media (prefers-color-scheme: dark){
|
|
19
|
+
:root:not([data-theme="light"]){
|
|
20
|
+
color-scheme:dark;
|
|
21
|
+
--bg:#0D1117; --surface:#151A22; --text:#E9EDF2; --muted:#8C95A3; --line:#252C37;
|
|
22
|
+
--accent:#2FD59B;
|
|
23
|
+
--skin-ink:#FFFFFF; --skin-eye:#2FD59B;
|
|
24
|
+
--wall:#10151C; --dot:#232B37; --shadow:rgba(0,0,0,.32);
|
|
25
|
+
--sheen-top:rgba(255,255,255,.09); --sheen-bottom:rgba(0,0,0,.16);
|
|
26
|
+
--said-bg:#2C3230; --said-ink:#E6EAE8;
|
|
27
|
+
--blush:#FF7F9E; --tear:#6BBDF7; --anger:#FF6369; --heart:#FF6F93; --dust:#5B6472; --warn:#C4A372;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
:root[data-theme="dark"]{
|
|
31
|
+
color-scheme:dark;
|
|
32
|
+
--bg:#0D1117; --surface:#151A22; --text:#E9EDF2; --muted:#8C95A3; --line:#252C37;
|
|
33
|
+
--accent:#2FD59B;
|
|
34
|
+
--skin-ink:#FFFFFF; --skin-eye:#2FD59B;
|
|
35
|
+
--wall:#10151C; --dot:#232B37; --shadow:rgba(0,0,0,.32);
|
|
36
|
+
--sheen-top:rgba(255,255,255,.09); --sheen-bottom:rgba(0,0,0,.16);
|
|
37
|
+
--said-bg:#2C3230; --said-ink:#E6EAE8;
|
|
38
|
+
--blush:#FF7F9E; --tear:#6BBDF7; --anger:#FF6369; --heart:#FF6F93; --dust:#5B6472; --warn:#C4A372;
|
|
39
|
+
}
|
|
40
|
+
/* the controls and bubbles drawn over the desktop, a little see-through and lit from above: the controls' face lets the
|
|
41
|
+
desktop show through while their rings and icons stay solid; a bubble fades as a whole (--bubble-alpha), so its tail,
|
|
42
|
+
which covers the border where it joins, stays seamless. --sheen is the light from above, --lift their two-layer shadow.
|
|
43
|
+
--halo, the ring a pointed button gets, is a colour change: it stays at medium motion and comes at once at low. */
|
|
44
|
+
:root{
|
|
45
|
+
--glass:color-mix(in srgb, var(--surface) 90%, transparent);
|
|
46
|
+
--sheen:linear-gradient(180deg, var(--sheen-top), var(--sheen-bottom));
|
|
47
|
+
--lift:0 1px 2px var(--shadow), 0 6px 16px var(--shadow);
|
|
48
|
+
--halo:0 0 0 4px color-mix(in srgb, var(--skin-eye) 16%, transparent);
|
|
49
|
+
--bubble-alpha:.94;
|
|
50
|
+
}
|
|
51
|
+
*{box-sizing:border-box}
|
|
52
|
+
html,body{margin:0; height:100%; overflow:hidden}
|
|
53
|
+
body{
|
|
54
|
+
font-family:system-ui,-apple-system,"Segoe UI","Noto Sans",sans-serif;
|
|
55
|
+
font-size:15px; line-height:1.55; color:var(--text);
|
|
56
|
+
user-select:none; -webkit-user-select:none;
|
|
57
|
+
}
|
|
58
|
+
/* line icons (ui.js): one line weight at every size, the same as the settings window's */
|
|
59
|
+
svg[viewBox="0 0 24 24"][stroke="currentColor"]{stroke-width:1.6px}
|
|
60
|
+
svg[viewBox="0 0 24 24"][stroke="currentColor"] *{vector-effect:non-scaling-stroke}
|
|
61
|
+
/* the app language is on <html lang> (web/i18n.js): each CJK script gets its own fonts, Latin and Cyrillic the system's */
|
|
62
|
+
:lang(zh) body{font-family:"Noto Sans SC","PingFang SC","Microsoft YaHei",system-ui,sans-serif}
|
|
63
|
+
:lang(zh-Hant) body{font-family:"Noto Sans TC","PingFang TC","Microsoft JhengHei",system-ui,sans-serif}
|
|
64
|
+
:lang(ja) body{font-family:"Noto Sans JP","Hiragino Sans","Hiragino Kaku Gothic ProN","Yu Gothic UI",Meiryo,system-ui,sans-serif}
|
|
65
|
+
:lang(ko) body{font-family:"Noto Sans KR","Apple SD Gothic Neo","Malgun Gothic",system-ui,sans-serif}
|
|
66
|
+
/* in a browser tab the page draws its own wall and floor; in the pet window it is transparent */
|
|
67
|
+
body.tab{
|
|
68
|
+
background-color:var(--wall);
|
|
69
|
+
background-image:radial-gradient(var(--dot) 1.2px, transparent 1.3px);
|
|
70
|
+
background-size:22px 22px;
|
|
71
|
+
}
|
|
72
|
+
body.tab .floor{position:fixed; left:0; right:0; bottom:0; height:48px; background:var(--surface); border-top:1px solid var(--line)}
|
|
73
|
+
/* the wall (stage.js lightWall): a soft light and a lens of bigger, eye-colored dots follow the pointer; both are
|
|
74
|
+
composited layers moved by transform, under everything else on the wall */
|
|
75
|
+
.wall{isolation:isolate}
|
|
76
|
+
.wall-glow, .wall-lens{position:absolute; left:0; top:0; z-index:-1; pointer-events:none; opacity:0; transition:opacity .45s ease; will-change:transform, opacity}
|
|
77
|
+
.wall-lit > .wall-glow, .wall-lit > .wall-lens{opacity:1}
|
|
78
|
+
/* --glow: the body's color (stage.js setGlow); without one, the settings window's theme color, else the page's */
|
|
79
|
+
.wall-glow{width:560px; height:560px; border-radius:50%; background:radial-gradient(circle closest-side, color-mix(in srgb, var(--glow, var(--host-accent, var(--accent))) 16%, transparent), transparent)}
|
|
80
|
+
.wall-lens{
|
|
81
|
+
width:300px; height:300px; overflow:hidden; border-radius:50%;
|
|
82
|
+
-webkit-mask-image:radial-gradient(circle closest-side, #000 0, rgba(0,0,0,.4) 50%, transparent 100%);
|
|
83
|
+
mask-image:radial-gradient(circle closest-side, #000 0, rgba(0,0,0,.4) 50%, transparent 100%);
|
|
84
|
+
}
|
|
85
|
+
.wall-lens-grid{
|
|
86
|
+
position:absolute; left:0; top:0; width:4000px; height:3000px; will-change:transform;
|
|
87
|
+
background-image:radial-gradient(color-mix(in srgb, var(--glow, var(--host-accent, var(--accent))) 70%, var(--dot)) 2.3px, transparent 2.6px); background-size:22px 22px;
|
|
88
|
+
}
|
|
89
|
+
/* the floor's row of taskbar icons, decoration only */
|
|
90
|
+
.floor-icons{position:absolute; inset:0; display:flex; align-items:center; justify-content:center; gap:26px; color:var(--muted); opacity:.75; pointer-events:none}
|
|
91
|
+
.floor-icons svg{width:18px; height:18px; display:block}
|
|
92
|
+
/* the night/day button at the stage's top left */
|
|
93
|
+
.stage-mode{
|
|
94
|
+
position:absolute; top:12px; left:12px; z-index:2; display:grid; place-items:center; width:32px; height:32px; padding:0;
|
|
95
|
+
border-radius:50%; border:1px solid var(--line); background:var(--sheen), var(--glass); color:var(--text); cursor:pointer;
|
|
96
|
+
box-shadow:0 1px 2px var(--shadow), 0 4px 12px var(--shadow); transition:color var(--motion-fast), border-color var(--motion-fast), transform var(--motion-fast);
|
|
97
|
+
}
|
|
98
|
+
body.tab .stage-mode{position:fixed}
|
|
99
|
+
.stage-mode:hover{color:var(--skin-eye); border-color:var(--skin-eye); transform:scale(1.06)}
|
|
100
|
+
.stage-mode svg{width:17px; height:17px; display:block}
|
|
101
|
+
body.desk{background:transparent}
|
|
102
|
+
body.desk .floor{display:none}
|
|
103
|
+
/* --pet-opacity: the transparency on screen (pet-app.js stepFade), on the body only, never on a bubble or a control */
|
|
104
|
+
.stage{position:fixed; inset:0; touch-action:none; opacity:var(--pet-opacity, 1); transition:opacity var(--motion-base) ease}
|
|
105
|
+
:where(:root[data-motion="low"]) {.stage{transition:none}}
|
|
106
|
+
/* the body's sandboxed frame: transparent (a colour scheme unlike the frame's would give it a backdrop) and never under the pointer */
|
|
107
|
+
.figure-layer{position:absolute; inset:0; pointer-events:none}
|
|
108
|
+
/* the frame's window onto the stage: body-host cuts it down to the body's surroundings while the halo is on */
|
|
109
|
+
.figure-layer .figure-clip{position:absolute; inset:0; pointer-events:none}
|
|
110
|
+
.figure-layer iframe{position:absolute; inset:0; width:100%; height:100%; border:0; background:transparent; color-scheme:normal; pointer-events:none}
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
/* activity borrows the speech bubble, but never takes the pointer or competes with dialogue */
|
|
114
|
+
.bubble.status{
|
|
115
|
+
display:flex; align-items:center; gap:6px;
|
|
116
|
+
max-width:min(calc(220px * var(--bubble-size, 1)), calc(100vw - 20px)); padding:calc(6px * var(--bubble-size, 1)) calc(10px * var(--bubble-size, 1));
|
|
117
|
+
font-size:calc(12.5px * var(--bubble-font, 1)); line-height:1.4; pointer-events:none; user-select:none; transition:opacity var(--motion-base);
|
|
118
|
+
}
|
|
119
|
+
.status[hidden]{display:none}
|
|
120
|
+
.status.fading{opacity:0}
|
|
121
|
+
.bubble.status.pop{animation:rise-in var(--motion-base) var(--motion-pop-soft); --rise:3px}
|
|
122
|
+
.status-text{overflow:hidden; text-overflow:ellipsis; white-space:nowrap}
|
|
123
|
+
.status-icon{display:flex; flex:none; color:color-mix(in srgb, var(--skin-eye) 78%, var(--skin-ink))}
|
|
124
|
+
.status-icon svg{width:calc(14px * var(--bubble-font, 1)); height:calc(14px * var(--bubble-font, 1)); overflow:visible}
|
|
125
|
+
.status[data-kind="think"]{justify-content:center}
|
|
126
|
+
.status[data-kind="think"] .status-text{display:none}
|
|
127
|
+
.status[data-kind="think"] .status-icon svg{width:calc(24px * var(--bubble-font, 1))}
|
|
128
|
+
.status-icon svg, .status-icon svg *{transform-box:fill-box; transform-origin:center}
|
|
129
|
+
.status[data-kind="think"] circle{animation:status-think 1.3s ease-in-out infinite}
|
|
130
|
+
.status[data-kind="think"] circle:nth-child(2){animation-delay:.16s}
|
|
131
|
+
.status[data-kind="think"] circle:nth-child(3){animation-delay:.32s}
|
|
132
|
+
.status .scan{animation:status-read 1.8s ease-in-out infinite}
|
|
133
|
+
.status .flap{transform-origin:center bottom; animation:status-browse 1.6s ease-in-out infinite}
|
|
134
|
+
.status[data-kind="search"] svg{animation:status-search 2s linear infinite}
|
|
135
|
+
.status[data-kind="write"] svg{animation:status-write 1.2s ease-in-out infinite}
|
|
136
|
+
.status .lid{transform-origin:left bottom; animation:status-delete 1.5s ease-in-out infinite}
|
|
137
|
+
.status .arrow{animation:status-save 1.5s ease-in-out infinite}
|
|
138
|
+
.status .pupil{animation:status-look 2.2s ease-in-out infinite}
|
|
139
|
+
.status .ripple{animation:status-click 1.2s ease-out infinite}
|
|
140
|
+
.status .wheel{animation:status-scroll 1.1s ease-in-out infinite}
|
|
141
|
+
.status .keycap{animation:status-type .9s ease-in-out infinite}
|
|
142
|
+
.status[data-kind="wait"] svg{animation:status-wait 2.8s ease-in-out infinite}
|
|
143
|
+
.status[data-kind="alarm"] svg{animation:status-alarm 1.8s ease-in-out infinite}
|
|
144
|
+
.status[data-kind="work"] svg{animation:spin 4s linear infinite}
|
|
145
|
+
@keyframes status-think{0%,60%,100%{transform:none; opacity:.45} 30%{transform:translateY(-3px); opacity:1}}
|
|
146
|
+
@keyframes status-read{0%,100%{transform:translateY(0); opacity:.5} 70%{transform:translateY(6px); opacity:1}}
|
|
147
|
+
@keyframes status-browse{50%{transform:scaleY(.72) skewX(-8deg)}}
|
|
148
|
+
@keyframes status-search{0%,100%{transform:translate(-1px,0)} 25%{transform:translate(0,-1px)} 50%{transform:translate(1px,0)} 75%{transform:translate(0,1px)}}
|
|
149
|
+
@keyframes status-write{0%,100%{transform:translate(-1px,1px) rotate(-5deg)} 50%{transform:translate(1px,-1px) rotate(5deg)}}
|
|
150
|
+
@keyframes status-delete{20%,60%{transform:rotate(-12deg)} 40%,80%{transform:none}}
|
|
151
|
+
@keyframes status-save{0%{transform:translateY(-3px); opacity:.3} 70%,100%{transform:translateY(2px); opacity:1}}
|
|
152
|
+
@keyframes status-look{25%{transform:translateX(-2px)} 75%{transform:translateX(2px)}}
|
|
153
|
+
@keyframes status-click{0%{transform:scale(.7); opacity:0} 35%{opacity:1} 100%{transform:scale(1.4); opacity:0}}
|
|
154
|
+
@keyframes status-scroll{0%{transform:translateY(-1px) scaleY(1); opacity:.4} 50%{transform:translateY(2px) scaleY(.5); opacity:1} 100%{transform:translateY(-1px) scaleY(1); opacity:.4}}
|
|
155
|
+
@keyframes status-type{40%,65%{transform:translateY(3px)}}
|
|
156
|
+
@keyframes status-wait{0%,30%{transform:rotate(0)} 60%,100%{transform:rotate(180deg)}}
|
|
157
|
+
@keyframes status-alarm{10%,30%{transform:rotate(-10deg)} 20%,40%{transform:rotate(10deg)} 50%,100%{transform:none}}
|
|
158
|
+
@keyframes spin{to{transform:rotate(360deg)}}
|
|
159
|
+
|
|
160
|
+
/* bubbles; the min-width keeps an empty one (its line not typed yet) wide enough for the tail to sit on its bottom edge.
|
|
161
|
+
--bubble-size scales the frame (widths, padding, corners, tail) and --bubble-font the text and the icons on its lines, both
|
|
162
|
+
factors set by pet-app.js from the bubbleSize and fontSize settings and unset at 1; the border keeps its line. */
|
|
163
|
+
.bubble{
|
|
164
|
+
position:fixed; left:0; top:0; z-index:3; width:max-content; min-width:calc(58px * var(--bubble-size, 1)); max-width:min(calc(300px * var(--bubble-size, 1)), calc(100vw - 20px));
|
|
165
|
+
padding:calc(10px * var(--bubble-size, 1)) calc(14px * var(--bubble-size, 1)); border-radius:calc(18px * var(--bubble-size, 1));
|
|
166
|
+
background:linear-gradient(180deg, var(--sheen-top), transparent 45%), var(--surface); color:var(--text);
|
|
167
|
+
border:2.5px solid var(--skin-ink); box-shadow:0 1px 3px var(--shadow), 0 8px 22px var(--shadow);
|
|
168
|
+
font-size:calc(14.5px * var(--bubble-font, 1)); line-height:1.55;
|
|
169
|
+
transform-origin:var(--tail, 50%) calc(100% + calc(10px * var(--bubble-size, 1)));
|
|
170
|
+
opacity:var(--bubble-alpha); transition:opacity var(--motion-base) ease;
|
|
171
|
+
}
|
|
172
|
+
/* tail: an outline triangle whose base lies inside the border, so its sides join the border, and a
|
|
173
|
+
surface triangle one line width inside it that opens the border between the sides. Neither is
|
|
174
|
+
rotated. y=0 is the padding edge, the border spans 0..2.5, the tip sits 8.5px past the border, at
|
|
175
|
+
--tail from the outer left edge (the same point transform-origin scales from). The outline's base
|
|
176
|
+
sits .75px into the border: the border is drawn on whole device pixels and the triangle is not, so a
|
|
177
|
+
base on the border's inner edge showed as a nub above the line at each corner of the tail. */
|
|
178
|
+
.bubble::before, .bubble::after{
|
|
179
|
+
content:""; position:absolute; left:calc(var(--tail, 50%) - 13.5px); bottom:-11px; width:22px; height:11.5px;
|
|
180
|
+
/* grown from where it meets the border, the tip staying on --tail */
|
|
181
|
+
scale:var(--bubble-size, none); transform-origin:11px 0;
|
|
182
|
+
}
|
|
183
|
+
.bubble::before{background:var(--skin-ink); clip-path:path('M0.75 1.25 L8.9 9.4 Q11 11.5 13.1 9.4 L21.25 1.25 Z')}
|
|
184
|
+
/* the surface triangle is the outline one moved up by the line's width across its 45° sides (--tail-line × √2, set by
|
|
185
|
+
pet-app.js to the width the border is drawn at), unscaled, so the tail's line matches the border at any --bubble-size */
|
|
186
|
+
.bubble::after{background:var(--surface); clip-path:path('M0.75 1.25 L8.9 9.4 Q11 11.5 13.1 9.4 L21.25 1.25 Z'); translate:0 calc(var(--tail-line, 2.5px) * -1.4142)}
|
|
187
|
+
.bubble.heard{background:linear-gradient(180deg, var(--sheen-top), transparent 45%), var(--said-bg); color:var(--said-ink); border-color:transparent; box-shadow:0 4px 14px var(--shadow); max-width:min(calc(260px * var(--bubble-size, 1)), calc(100vw - 20px))}
|
|
188
|
+
.bubble.heard::before, .bubble.heard::after{display:none}
|
|
189
|
+
/* what the person said, above Coo (pet-app.js lines): a settled one closes on a click, lit in the eye color on hover as the
|
|
190
|
+
hover buttons are; older ones step back; a fading one lets the pointer through. Its text shows six rows at most. */
|
|
191
|
+
.bubble.said{transition:opacity .4s ease, border-color var(--motion-fast)}
|
|
192
|
+
.bubble.said.settled{cursor:pointer}
|
|
193
|
+
.bubble.said.settled:hover{border-color:var(--skin-eye); opacity:var(--bubble-alpha)}
|
|
194
|
+
.bubble.said.older{opacity:calc(.62 * var(--bubble-alpha))}
|
|
195
|
+
.bubble.said.fading{opacity:0; pointer-events:none}
|
|
196
|
+
.bubble.said.settled .b-text{display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:6; line-clamp:6; overflow:hidden}
|
|
197
|
+
/* the way a line came, before its text: the voice button's microphone, the chat page's arrows */
|
|
198
|
+
.said-mark{display:inline-flex; vertical-align:-2px; margin-right:5px; color:color-mix(in srgb, var(--skin-eye) 78%, var(--skin-ink))}
|
|
199
|
+
.said-mark svg{width:calc(15px * var(--bubble-font, 1)); height:calc(15px * var(--bubble-font, 1))}
|
|
200
|
+
.b-hint .said-mark{vertical-align:-3px; margin-right:4px}
|
|
201
|
+
/* a line closes on a click, lit in the eye color on hover as the person's own lines are */
|
|
202
|
+
.bubble.say{cursor:pointer; transition:opacity .4s ease, border-color var(--motion-fast)}
|
|
203
|
+
.bubble.say:hover{border-color:var(--skin-eye)}
|
|
204
|
+
.bubble.say:hover::before{background:var(--skin-eye)}
|
|
205
|
+
.bubble.say.fading{opacity:0; pointer-events:none}
|
|
206
|
+
.bubble.ask{min-width:min(calc(236px * var(--bubble-size, 1)), calc(100vw - 20px))}
|
|
207
|
+
.bubble.pop{animation:bubble-in var(--motion-slow) var(--motion-pop)}
|
|
208
|
+
@keyframes bubble-in{from{transform:scale(.5); opacity:0}}
|
|
209
|
+
.b-text{margin:0; min-height:1.55em; white-space:pre-wrap; text-wrap:pretty; overflow-wrap:break-word}
|
|
210
|
+
.b-text .interim{color:var(--muted)}
|
|
211
|
+
.b-text a{color:var(--skin-eye); text-decoration:underline; text-underline-offset:2px; overflow-wrap:anywhere}
|
|
212
|
+
.caret{display:inline-block; width:2px; height:1.05em; margin-left:2px; vertical-align:-2px; background:var(--skin-eye); animation:caret 1s steps(1) infinite}
|
|
213
|
+
@keyframes caret{50%{opacity:0}}
|
|
214
|
+
.b-hint{display:block; margin-top:2px; font-size:calc(12px * var(--bubble-font, 1)); color:var(--muted)}
|
|
215
|
+
.b-foot{display:flex; align-items:center; gap:8px; margin-top:2px}
|
|
216
|
+
.b-foot .b-hint{flex:1; margin-top:0}
|
|
217
|
+
.b-cancel{flex:none; font:inherit; font-size:calc(12px * var(--bubble-font, 1)); padding:2px 9px; border-radius:8px; border:1.5px solid var(--line); background:none; color:var(--muted); cursor:pointer}
|
|
218
|
+
.b-cancel:hover{color:var(--text); border-color:var(--text)}
|
|
219
|
+
.caret[hidden], .b-cancel[hidden]{display:none}
|
|
220
|
+
.b-opts{display:flex; flex-direction:column; gap:6px; margin:10px 0 2px}
|
|
221
|
+
.b-opt, .b-own{animation:rise-in var(--motion-base) var(--motion-pop-soft) both; transition:border-color var(--motion-fast), opacity var(--motion-base)}
|
|
222
|
+
/* rising into place: `--rise` and `--rise-scale` set the start (6px below, at 92%) */
|
|
223
|
+
@property --rise{syntax:'<length>'; inherits:false; initial-value:6px}
|
|
224
|
+
@property --rise-scale{syntax:'<number>'; inherits:false; initial-value:.92}
|
|
225
|
+
@keyframes rise-in{from{transform:translateY(var(--rise)) scale(var(--rise-scale)); opacity:0}}
|
|
226
|
+
.b-opt{
|
|
227
|
+
display:flex; align-items:center; gap:8px; width:100%; text-align:left; font:inherit; font-size:calc(14px * var(--bubble-font, 1));
|
|
228
|
+
padding:6px 10px; border-radius:11px; border:1.5px solid var(--line); background:var(--bg); color:var(--text); cursor:pointer;
|
|
229
|
+
}
|
|
230
|
+
.b-opt:hover, .b-opt.chosen{border-color:var(--skin-eye)}
|
|
231
|
+
.b-opt kbd{
|
|
232
|
+
flex:none; display:grid; place-items:center; width:calc(20px * var(--bubble-font, 1)); height:calc(20px * var(--bubble-font, 1)); border-radius:50%;
|
|
233
|
+
border:2px solid var(--skin-eye); font:500 calc(11px * var(--bubble-font, 1))/1 ui-monospace,Consolas,monospace; color:var(--text);
|
|
234
|
+
}
|
|
235
|
+
.b-own{display:flex; align-items:flex-end; gap:6px; padding:3px 3px 3px 10px; border-radius:11px; border:1.5px dashed var(--line); background:var(--bg)}
|
|
236
|
+
.b-own:focus-within, .b-own.chosen{border-style:solid; border-color:var(--skin-eye)}
|
|
237
|
+
.b-own input, .b-own textarea{flex:1; min-width:0; border:0; background:transparent; font:inherit; font-size:calc(14px * var(--bubble-font, 1)); color:var(--text); outline:none; padding:4px 0}
|
|
238
|
+
/* the typed line grows with its text up to six rows, then scrolls */
|
|
239
|
+
.b-own textarea{resize:none; field-sizing:content; line-height:1.4; max-height:calc(6 * 1.4em + 8px); overflow-y:auto; overflow-wrap:anywhere}
|
|
240
|
+
/* once the text takes a second row (pet-app.js `tall`) it gets the field's whole width and the buttons go under it */
|
|
241
|
+
.b-own.tall{flex-wrap:wrap; justify-content:flex-end; row-gap:2px}
|
|
242
|
+
/* its right edge as far from the field's border as its left (the field's padding is 3px on the right, 10px on the left) */
|
|
243
|
+
.b-own.tall textarea{flex:0 0 100%; padding-right:7px}
|
|
244
|
+
/* a bubble with a close button keeps it outside, on its right (pet-app.js sideColumn): a small round button as the
|
|
245
|
+
hover buttons are drawn, and for the typing box, under it, centred, a thumb on a faint track while the text
|
|
246
|
+
scrolls; the textarea's own scrollbar is not shown */
|
|
247
|
+
.b-own textarea{scrollbar-width:none}
|
|
248
|
+
/* text that runs on past the field's top or bottom fades out at that edge, over about a row */
|
|
249
|
+
.b-own textarea.scrolls{
|
|
250
|
+
--above:0px; --below:0px;
|
|
251
|
+
mask-image:linear-gradient(to bottom, transparent, #000 var(--above), #000 calc(100% - var(--below)), transparent);
|
|
252
|
+
}
|
|
253
|
+
.b-own textarea.more-above{--above:1.4em}
|
|
254
|
+
.b-own textarea.more-below{--below:1.4em}
|
|
255
|
+
.b-side{position:absolute; left:calc(100% + 8.5px); top:-2.5px; display:flex; flex-direction:column; align-items:center; gap:6px; width:26px}
|
|
256
|
+
.b-close{
|
|
257
|
+
display:grid; place-items:center; width:26px; height:26px; padding:0; border-radius:50%; cursor:pointer;
|
|
258
|
+
background:var(--sheen), var(--glass); color:var(--text); border:2px solid var(--skin-ink); box-shadow:0 1px 2px var(--shadow), 0 4px 12px var(--shadow);
|
|
259
|
+
transition:border-color var(--motion-fast), color var(--motion-fast), scale var(--motion-fast) ease, box-shadow var(--motion-fast);
|
|
260
|
+
}
|
|
261
|
+
.b-close:hover{color:var(--skin-eye); border-color:var(--skin-eye); scale:1.1; box-shadow:var(--halo), 0 1px 2px var(--shadow), 0 4px 12px var(--shadow)}
|
|
262
|
+
.b-close svg{display:block; width:12px; height:12px; fill:none; stroke:currentColor; stroke-width:2px; stroke-linecap:round}
|
|
263
|
+
.b-track{position:relative; width:6px; border-radius:3px; background:color-mix(in srgb, var(--line) 60%, transparent); cursor:pointer; touch-action:none}
|
|
264
|
+
.b-thumb{position:absolute; left:0; width:6px; min-height:16px; border-radius:3px; background:var(--muted); opacity:.75; transition:opacity var(--motion-fast)}
|
|
265
|
+
.b-track:hover .b-thumb, .b-track.held .b-thumb{opacity:1}
|
|
266
|
+
.b-own button[type="submit"]{flex:none; font:inherit; font-size:calc(12.5px * var(--bubble-font, 1)); padding:4px 10px; border-radius:8px; border:0; background:var(--text); color:var(--surface); cursor:pointer}
|
|
267
|
+
.b-expand{flex:none; display:grid; place-items:center; width:26px; height:26px; padding:0; border:0; border-radius:50%; background:none; color:var(--muted); cursor:pointer}
|
|
268
|
+
.b-expand:hover{color:var(--text)}
|
|
269
|
+
.b-expand svg{width:15px; height:15px; fill:none; stroke:currentColor; stroke-width:1.6px; stroke-linecap:round; stroke-linejoin:round}
|
|
270
|
+
.b-expand svg *{vector-effect:non-scaling-stroke}
|
|
271
|
+
.b-opt.dim, .b-own.dim{opacity:.35}
|
|
272
|
+
/* pictures pasted into the typing box: one row of thumbnails above it; the box holds no more than fits */
|
|
273
|
+
.b-imgs{display:flex; gap:6px; margin-bottom:8px}
|
|
274
|
+
.b-imgs[hidden], .b-note[hidden], .b-limit[hidden]{display:none}
|
|
275
|
+
.b-img{position:relative; flex:none; width:calc(44px * var(--bubble-size, 1)); height:calc(44px * var(--bubble-size, 1)); border-radius:8px; overflow:hidden; border:1px solid var(--line); background:var(--bg)}
|
|
276
|
+
.b-img img{display:block; width:100%; height:100%; object-fit:cover}
|
|
277
|
+
.b-img button{position:absolute; top:2px; right:2px; width:18px; height:18px; padding:0; border:0; border-radius:50%; background:rgba(0,0,0,.55); color:#fff; font-size:13px; line-height:18px; cursor:pointer}
|
|
278
|
+
.b-note{margin-top:6px}
|
|
279
|
+
/* an app's conversation: one step per bubble, with the answer's controls under Coo's line */
|
|
280
|
+
.d-mark{color:var(--skin-eye); font-weight:700}
|
|
281
|
+
.bubble.talk{width:min(calc(318px * var(--bubble-size, 1)), calc(100vw - 20px)); max-width:none; padding:calc(11px * var(--bubble-size, 1)) calc(14px * var(--bubble-size, 1)) calc(12px * var(--bubble-size, 1))}
|
|
282
|
+
.d-top{display:flex; align-items:center; min-height:14px; margin:-2px 0 5px}
|
|
283
|
+
.d-back{margin:0 5px 0 -3px; padding:1px 3px; border:0; border-radius:4px; background:none; font:inherit; font-size:calc(12.5px * var(--bubble-font, 1)); line-height:1.1; color:var(--muted); cursor:pointer}
|
|
284
|
+
.d-back:hover{color:var(--text); text-decoration:underline}
|
|
285
|
+
.d-dots{display:flex; gap:4px}
|
|
286
|
+
.d-dots i{width:6px; height:6px; border-radius:3px; background:var(--line); transition:width var(--motion-slow), background var(--motion-slow)}
|
|
287
|
+
.d-dots i.past{background:color-mix(in srgb, var(--skin-eye) 45%, var(--line))}
|
|
288
|
+
.d-dots i.on{width:16px; background:var(--skin-eye)}
|
|
289
|
+
.d-body{display:flex; flex-direction:column; gap:8px; margin-top:10px}
|
|
290
|
+
.d-body > *{animation:rise-in var(--motion-base) var(--motion-pop-soft) both}
|
|
291
|
+
.d-body button, .d-body input{font:inherit}
|
|
292
|
+
.d-row{display:flex; flex-wrap:wrap; justify-content:flex-end; gap:6px}
|
|
293
|
+
.d-pill{
|
|
294
|
+
padding:5px 14px; border-radius:999px; border:1.5px solid var(--line); background:var(--bg); color:var(--text);
|
|
295
|
+
font-size:calc(13.5px * var(--bubble-font, 1)); cursor:pointer; transition:border-color var(--motion-fast), background var(--motion-fast), transform var(--motion-fast);
|
|
296
|
+
}
|
|
297
|
+
.d-pill:hover{border-color:var(--skin-ink)}
|
|
298
|
+
.d-pill.primary{background:var(--skin-ink); border-color:var(--skin-ink); color:var(--surface); font-weight:600}
|
|
299
|
+
.d-pill.primary:hover{background:var(--skin-eye); border-color:var(--skin-eye)}
|
|
300
|
+
.d-pill.swap:not(:hover):not(:focus-visible) .d-pill-hover, .d-pill.swap:is(:hover, :focus-visible) .d-pill-rest{display:none}
|
|
301
|
+
.d-pill.chosen{animation:bump var(--motion-slow) var(--motion-pop)}
|
|
302
|
+
/* a short swell: `--bump` is the largest scale */
|
|
303
|
+
@property --bump{syntax:'<number>'; inherits:false; initial-value:1.1}
|
|
304
|
+
@keyframes bump{45%{transform:scale(var(--bump))}}
|
|
305
|
+
.d-body button:disabled{cursor:default}
|
|
306
|
+
/* the talk key as a key cap that keeps being pressed */
|
|
307
|
+
.d-keys{display:flex; justify-content:center; padding:4px 0 2px}
|
|
308
|
+
.d-key{
|
|
309
|
+
display:inline-block; padding:5px 16px 4px; border-radius:10px; border:2px solid var(--skin-ink); border-bottom-width:5px;
|
|
310
|
+
background:var(--surface); color:var(--text); font:600 calc(14px * var(--bubble-font, 1))/1.3 ui-monospace,Consolas,monospace;
|
|
311
|
+
animation:key-press 1.8s ease-in-out infinite;
|
|
312
|
+
}
|
|
313
|
+
@keyframes key-press{0%,35%,100%{transform:none; border-bottom-width:5px} 45%,80%{transform:translateY(3px); border-bottom-width:2px; border-color:var(--skin-eye); color:var(--skin-eye)}}
|
|
314
|
+
/* tapped, then held: a quick press, a quick release, and a long press lit in the eye color */
|
|
315
|
+
.d-key.taps{animation:key-taphold 2.2s ease-in-out infinite}
|
|
316
|
+
@keyframes key-taphold{
|
|
317
|
+
0%,20%,100%{transform:none; border-bottom-width:5px}
|
|
318
|
+
24%,28%{transform:translateY(3px); border-bottom-width:2px}
|
|
319
|
+
32%,36%{transform:none; border-bottom-width:5px}
|
|
320
|
+
40%,82%{transform:translateY(3px); border-bottom-width:2px; border-color:var(--skin-eye); color:var(--skin-eye)}
|
|
321
|
+
86%{transform:none; border-bottom-width:5px}
|
|
322
|
+
}
|
|
323
|
+
.d-keys{align-items:center; gap:6px}
|
|
324
|
+
.d-taps{font:700 calc(12px * var(--bubble-font, 1))/1 ui-monospace,Consolas,monospace; color:var(--muted)}
|
|
325
|
+
/* choice cards: the picked one lit in the eye color */
|
|
326
|
+
.d-cards{display:grid; grid-template-columns:repeat(auto-fit, minmax(80px, 1fr)); gap:6px}
|
|
327
|
+
/* while the cards grow to the rows the 「more」 card unfolded, the new rows stay inside them; the margin keeps level tags whole */
|
|
328
|
+
.d-cards.unfolding{overflow:clip; overflow-clip-margin:8px}
|
|
329
|
+
.d-card{
|
|
330
|
+
position:relative; display:flex; flex-direction:column; align-items:center; gap:4px; padding:10px 4px 8px; border-radius:14px;
|
|
331
|
+
border:1.5px solid var(--line); background:var(--bg); color:var(--text); cursor:pointer;
|
|
332
|
+
animation:rise-in var(--motion-base) var(--motion-pop-soft) both; transition:border-color var(--motion-fast), background var(--motion-fast), transform var(--motion-fast), color var(--motion-fast);
|
|
333
|
+
}
|
|
334
|
+
.d-card:hover{transform:translateY(-2px); border-color:var(--skin-ink)}
|
|
335
|
+
.d-card.on{border-color:var(--skin-eye); background:color-mix(in srgb, var(--skin-eye) 14%, var(--bg)); color:var(--skin-eye)}
|
|
336
|
+
.d-cardic svg{width:24px; height:24px; display:block}
|
|
337
|
+
.d-cardimg{width:28px; height:28px; display:block; padding:3px; border-radius:7px; background:#fff; box-sizing:border-box}
|
|
338
|
+
.d-card.on .d-cardimg{animation:card-bob .5s var(--motion-pop)}
|
|
339
|
+
.d-cardlbl{font-size:calc(13px * var(--bubble-font, 1)); line-height:1.25; overflow-wrap:anywhere; color:var(--text)}
|
|
340
|
+
.d-cardnote{font-size:calc(11px * var(--bubble-font, 1)); line-height:1.35; color:var(--muted); text-align:center}
|
|
341
|
+
.d-level{
|
|
342
|
+
position:absolute; top:-7px; right:-5px; min-width:18px; padding:0 4px; border-radius:7px; border:1.5px solid var(--surface);
|
|
343
|
+
background:var(--muted); color:var(--surface); font:700 calc(10px * var(--bubble-font, 1))/calc(15px * var(--bubble-font, 1)) system-ui,sans-serif;
|
|
344
|
+
}
|
|
345
|
+
.d-card.on .d-level{background:var(--skin-eye)}
|
|
346
|
+
.d-card.on .d-cardic{animation:card-bob .5s var(--motion-pop)}
|
|
347
|
+
@keyframes card-bob{40%{transform:translateY(-4px) rotate(-8deg)}}
|
|
348
|
+
/* cards one per row, the icon before the label */
|
|
349
|
+
.d-cards.list{grid-template-columns:1fr}
|
|
350
|
+
/* a pick: four small cards to a row; at the most, the ones not picked fade until one is put out */
|
|
351
|
+
.d-cards.pick{grid-template-columns:repeat(4, minmax(0, 1fr))}
|
|
352
|
+
.d-cards.pick .d-card:disabled{opacity:.4; transform:none; border-color:var(--line); cursor:default}
|
|
353
|
+
.d-pill.need{opacity:.45; cursor:default}
|
|
354
|
+
.d-cards.list .d-card{flex-direction:row; justify-content:center; gap:8px; padding:8px 12px; border-radius:12px}
|
|
355
|
+
.d-cards.list .d-cardlbl{font-size:calc(14px * var(--bubble-font, 1))}
|
|
356
|
+
.d-cards.list .d-cardic svg{width:18px; height:18px}
|
|
357
|
+
/* a card's own colour on its icon (`tint`) */
|
|
358
|
+
.d-card.tint .d-cardic{color:var(--tint-l)}
|
|
359
|
+
:root[data-theme="dark"] .d-card.tint .d-cardic{color:var(--tint-d)}
|
|
360
|
+
@media (prefers-color-scheme: dark){:root:not([data-theme="light"]) .d-card.tint .d-cardic{color:var(--tint-d)}}
|
|
361
|
+
/* the personas' icons act out their card once it is picked: looking around, tipping, two knocks, two beats, drifting, a spout */
|
|
362
|
+
.d-card.on .d-cardic.ic-persona_coo{animation:ic-look 1.1s ease-in-out}
|
|
363
|
+
.d-card.on .d-cardic.ic-persona_grail{transform-origin:50% 85%; animation:ic-tip .9s ease-in-out}
|
|
364
|
+
.d-card.on .d-cardic.ic-persona_forge{transform-origin:19% 77%; animation:ic-knock .8s ease-in}
|
|
365
|
+
.d-card.on .d-cardic.ic-persona_heart{animation:ic-beat .9s ease-out}
|
|
366
|
+
.d-card.on .d-cardic.ic-persona_winter{animation:ic-drift 1.4s ease-in-out}
|
|
367
|
+
.d-card.on .d-cardic.ic-persona_whale{animation:ic-float 1s ease-in-out}
|
|
368
|
+
.d-card.on .d-cardic.ic-persona_whale .spout{transform-box:fill-box; transform-origin:50% 100%; animation:ic-spout 1s ease-out}
|
|
369
|
+
@keyframes ic-look{20%{transform:translate(-2.5px,0)} 45%{transform:translate(2.5px,-1.5px)} 70%{transform:translate(1px,2px)} 100%{transform:none}}
|
|
370
|
+
@keyframes ic-tip{30%{transform:rotate(-18deg)} 60%{transform:rotate(8deg)} 100%{transform:none}}
|
|
371
|
+
@keyframes ic-knock{18%{transform:rotate(-30deg)} 32%{transform:rotate(4deg)} 44%{transform:none} 62%{transform:rotate(-30deg)} 78%{transform:rotate(4deg)} 90%,100%{transform:none}}
|
|
372
|
+
@keyframes ic-beat{15%{transform:scale(1.28)} 30%{transform:scale(1)} 45%{transform:scale(1.2)} 65%,100%{transform:scale(1)}}
|
|
373
|
+
@keyframes ic-drift{35%{transform:translate(-3px,-2px) rotate(-35deg)} 70%{transform:translate(2px,1px) rotate(20deg)} 100%{transform:none}}
|
|
374
|
+
@keyframes ic-float{30%{transform:translateY(1.5px)} 60%{transform:translateY(-1px)} 100%{transform:none}}
|
|
375
|
+
@keyframes ic-spout{0%{transform:scaleY(.3); opacity:0} 40%{transform:scaleY(1.5) translateY(-1px); opacity:1} 100%{transform:none}}
|
|
376
|
+
/* the line beside the confirm button, its marked word after an icon */
|
|
377
|
+
.d-foot-row{justify-content:space-between; align-items:center}
|
|
378
|
+
.d-hint{display:inline-flex; align-items:center; gap:3px; font-size:calc(12px * var(--bubble-font, 1)); color:var(--muted)}
|
|
379
|
+
.d-hint b{display:inline-flex; align-items:center; gap:2px; font-weight:500; color:var(--text)}
|
|
380
|
+
.d-hint svg{width:calc(14px * var(--bubble-font, 1)); height:calc(14px * var(--bubble-font, 1)); display:block}
|
|
381
|
+
/* a text box with its send button; a secret one can be peeked at */
|
|
382
|
+
.d-field{display:flex; align-items:center; gap:4px; padding:3px 3px 3px 11px; border-radius:12px; border:1.5px solid var(--line); background:var(--bg)}
|
|
383
|
+
.d-field:focus-within{border-color:var(--skin-eye)}
|
|
384
|
+
.d-field input{flex:1; min-width:0; border:0; background:transparent; font-size:calc(14px * var(--bubble-font, 1)); color:var(--text); outline:none; padding:5px 0; user-select:text; -webkit-user-select:text}
|
|
385
|
+
.d-field .d-peek{flex:none; display:grid; place-items:center; width:26px; height:26px; padding:0; border:0; border-radius:50%; background:none; color:var(--muted); cursor:pointer}
|
|
386
|
+
.d-field .d-peek:hover{color:var(--text)}
|
|
387
|
+
.d-field .d-peek svg{width:16px; height:16px}
|
|
388
|
+
.d-send{flex:none; padding:5px 12px; border-radius:9px; border:0; background:var(--skin-ink); color:var(--surface); font-size:calc(13px * var(--bubble-font, 1)); font-weight:600; cursor:pointer}
|
|
389
|
+
.d-send:hover{background:var(--skin-eye)}
|
|
390
|
+
.d-field.shake, .b-own.shake{animation:field-shake .32s}
|
|
391
|
+
/* a typed text past its cap (pet-app.js capField): the field's border turns red, the count shows beside the send
|
|
392
|
+
button and the text is not sent */
|
|
393
|
+
.b-count{flex:none; align-self:center; font-size:calc(11.5px * var(--bubble-font, 1)); font-variant-numeric:tabular-nums; padding:0 2px; color:var(--anger)}
|
|
394
|
+
.b-own.over, .b-own.over:focus-within, .d-field.over, .d-field.over:focus-within{border-style:solid; border-color:var(--anger)}
|
|
395
|
+
/* in the typing box the count goes to the left of the row of buttons under the text */
|
|
396
|
+
.b-own.tall .b-count{margin-right:auto; padding-left:0}
|
|
397
|
+
.b-limit{margin-top:6px; color:var(--anger)}
|
|
398
|
+
.b-expand.nudge{color:var(--skin-eye)}
|
|
399
|
+
.b-own.over button[type="submit"], .d-field.over .d-send{opacity:.4; cursor:default}
|
|
400
|
+
.b-expand:disabled{opacity:.35; cursor:default}
|
|
401
|
+
@keyframes field-shake{20%,60%{transform:translateX(-4px)} 40%,80%{transform:translateX(4px)}}
|
|
402
|
+
.d-links{display:flex; align-items:center; justify-content:space-between; gap:8px; font-size:calc(12.5px * var(--bubble-font, 1))}
|
|
403
|
+
.d-link{display:inline-flex; align-items:center; gap:3px; color:var(--skin-eye); text-decoration:none}
|
|
404
|
+
.d-link:hover{text-decoration:underline}
|
|
405
|
+
.d-link svg{width:calc(12px * var(--bubble-font, 1)); height:calc(12px * var(--bubble-font, 1))}
|
|
406
|
+
.d-alt{margin-left:auto; padding:2px 4px; border:0; background:none; color:var(--muted); font-size:calc(12.5px * var(--bubble-font, 1)); cursor:pointer}
|
|
407
|
+
.d-alt:hover{color:var(--text); text-decoration:underline}
|
|
408
|
+
/* a progress bar; without a fraction a band slides along it */
|
|
409
|
+
.d-bar{position:relative; height:8px; border-radius:4px; background:var(--line); overflow:hidden}
|
|
410
|
+
.d-bar i{position:absolute; left:0; top:0; bottom:0; width:0; border-radius:4px; background:linear-gradient(90deg, var(--skin-eye), color-mix(in srgb, var(--skin-eye) 55%, #4CC9F0)); transition:width .4s ease}
|
|
411
|
+
.d-bar.wait i{width:35%; animation:bar-slide 1.2s ease-in-out infinite}
|
|
412
|
+
@keyframes bar-slide{from{left:-35%} to{left:100%}}
|
|
413
|
+
.d-barlbl{display:flex; justify-content:space-between; gap:8px; font-size:calc(12px * var(--bubble-font, 1)); color:var(--muted)}
|
|
414
|
+
.d-barlbl b{font-weight:600; font-variant-numeric:tabular-nums; color:var(--text)}
|
|
415
|
+
|
|
416
|
+
/* context menu: the run controls as round buttons on one side of the body, the actions in columns on the other */
|
|
417
|
+
.menu{position:fixed; inset:0; z-index:5; pointer-events:none}
|
|
418
|
+
.menu > *{position:fixed; pointer-events:auto}
|
|
419
|
+
/* the menu's buttons and the hover buttons: opening, each pops out of the body's side (`--dx`) one after another (`--i`);
|
|
420
|
+
closing, all fold back into it at once (POP_OUT_MS in pet-app.js), taking no clicks meanwhile */
|
|
421
|
+
.menu.entering :is(.m-grid, .m-rail) > *, .tools.entering > *{animation:m-in var(--motion-slow) var(--motion-pop) backwards; animation-delay:calc(var(--i, 0) * 22ms)}
|
|
422
|
+
.menu.leaving :is(.m-grid, .m-rail) > *, .tools.leaving > *{animation:m-out var(--pop-out) ease-in forwards}
|
|
423
|
+
.menu.leaving, .menu.leaving > *, .tools.leaving, .tools.leaving > *, .wheel.leaving{pointer-events:none}
|
|
424
|
+
/* a hover button that was showing slides into its tile instead of popping out again */
|
|
425
|
+
.menu.entering .m-grid > .from-tool{animation:m-move var(--motion-slow) cubic-bezier(.2,.8,.3,1) backwards; animation-delay:0s}
|
|
426
|
+
@keyframes m-move{from{transform:translate(var(--fx, 0), var(--fy, 0))}}
|
|
427
|
+
@keyframes m-in{from{transform:translateX(var(--dx, 0)) scale(.3); opacity:0}}
|
|
428
|
+
@keyframes m-out{to{transform:translateX(var(--dx, 0)) scale(.4); opacity:0}}
|
|
429
|
+
.menu [hidden]{display:none}
|
|
430
|
+
.menu button{font:inherit; cursor:pointer}
|
|
431
|
+
.m-rail{display:flex; flex-direction:column; gap:8px}
|
|
432
|
+
.m-rail > *{flex:none}
|
|
433
|
+
/* the run controls are hover buttons; only their icons take color, as in the settings window's rail:
|
|
434
|
+
power red, pause in the accent while running, resume amber while paused */
|
|
435
|
+
.m-rail > .tool.power, .m-rail > .tool.power:hover{color:var(--anger); border-color:var(--skin-ink)}
|
|
436
|
+
.m-rail > .tool.run, .m-rail > .tool.run:hover{color:var(--skin-eye); border-color:var(--skin-ink)}
|
|
437
|
+
.m-rail > .tool.run.paused, .m-rail > .tool.run.paused:hover{color:var(--warn)}
|
|
438
|
+
/* the quit question: the power button grown into a row of the prompt and the two answers */
|
|
439
|
+
.m-quit{
|
|
440
|
+
display:flex; align-items:center; gap:2px; box-sizing:border-box; height:38px; padding:0 0 0 10px; border-radius:19px; overflow:hidden; white-space:nowrap;
|
|
441
|
+
background:var(--sheen), var(--glass); border:2px solid var(--skin-ink); box-shadow:var(--lift); font-size:13px;
|
|
442
|
+
/* it grows from the power button and shrinks back into it by script (growFrom in motion-frames.js) */
|
|
443
|
+
}
|
|
444
|
+
.m-quit > *{flex:none}
|
|
445
|
+
.m-ask{padding-right:4px; line-height:1.3}
|
|
446
|
+
.q-act{display:grid; place-items:center; width:34px; height:34px; padding:0; border:0; border-radius:50%; background:none; color:var(--muted)}
|
|
447
|
+
.q-act:hover{background:var(--bg); color:var(--text)}
|
|
448
|
+
.q-act svg{width:20px; height:20px; display:block}
|
|
449
|
+
.q-act.danger{color:var(--anger)}
|
|
450
|
+
.q-act.text{width:auto; padding:0 10px; border-radius:15px; font-size:12.5px; white-space:nowrap}
|
|
451
|
+
/* the actions as the hover buttons draw them, filled column by column */
|
|
452
|
+
.m-grid{display:grid; grid-auto-flow:column; gap:8px}
|
|
453
|
+
.badge{
|
|
454
|
+
position:absolute; right:-9px; bottom:-8px; padding:0 3px; border-radius:6px; border:1.5px solid var(--surface);
|
|
455
|
+
background:var(--skin-eye); color:var(--surface); font:700 8.5px/12px ui-monospace,Consolas,monospace; letter-spacing:.02em; text-transform:uppercase;
|
|
456
|
+
}
|
|
457
|
+
/* dressing up: on hover the shirt wiggles through the palettes and three dots of color pop out */
|
|
458
|
+
.tool[data-action="dress"]:hover{animation:dress-hue 1.6s linear infinite}
|
|
459
|
+
.tool[data-action="dress"]:hover .ic{animation:dress-wiggle .5s ease-in-out}
|
|
460
|
+
.tool[data-action="dress"]::before, .tool[data-action="dress"]::after, .tool[data-action="dress"] .ic::before{
|
|
461
|
+
content:""; position:absolute; width:6px; height:6px; border-radius:50%; opacity:0; pointer-events:none;
|
|
462
|
+
}
|
|
463
|
+
.tool[data-action="dress"]::before{left:-2px; top:4px; background:#FF6B8B}
|
|
464
|
+
.tool[data-action="dress"]::after{right:-3px; top:0; background:#FFC43D}
|
|
465
|
+
.tool[data-action="dress"] .ic::before{left:7px; top:-19px; background:#4CC9F0}
|
|
466
|
+
.tool[data-action="dress"]:hover::before{animation:dress-pop .7s ease-out infinite}
|
|
467
|
+
.tool[data-action="dress"]:hover::after{animation:dress-pop .7s .23s ease-out infinite}
|
|
468
|
+
.tool[data-action="dress"]:hover .ic::before{animation:dress-pop .7s .46s ease-out infinite}
|
|
469
|
+
@keyframes dress-hue{
|
|
470
|
+
0%{color:#FF6B8B; border-color:#FF6B8B} 20%{color:#FF9F43; border-color:#FF9F43} 40%{color:#FFC43D; border-color:#FFC43D}
|
|
471
|
+
60%{color:#2FD59B; border-color:#2FD59B} 80%{color:#4CC9F0; border-color:#4CC9F0} 100%{color:#B388FF; border-color:#B388FF}
|
|
472
|
+
}
|
|
473
|
+
@keyframes dress-wiggle{25%{transform:rotate(-12deg)} 75%{transform:rotate(12deg)}}
|
|
474
|
+
@keyframes dress-pop{0%{opacity:0; transform:scale(.3) translate(0, 0)} 30%{opacity:1} 100%{opacity:0; transform:scale(1.1) translate(0, -8px)}}
|
|
475
|
+
/* look wheel: the looks in a row over the body; the farther from the middle, the smaller and fainter */
|
|
476
|
+
.wheel{position:fixed; z-index:6; height:62px}
|
|
477
|
+
/* folding into the middle (WHEEL_OUT_MS in pet-app.js) */
|
|
478
|
+
.wheel.leaving .w-item{transition-timing-function:ease-in; transition-duration:var(--wheel-out)}
|
|
479
|
+
.wheel[hidden]{display:none}
|
|
480
|
+
.w-item{
|
|
481
|
+
position:absolute; left:50%; top:50%; width:50px; height:50px; padding:0; border-radius:50%; overflow:hidden; cursor:pointer;
|
|
482
|
+
background:var(--sheen), var(--glass); border:2px solid var(--skin-ink); box-shadow:var(--lift);
|
|
483
|
+
transition:transform var(--motion-fast) cubic-bezier(.3,1.3,.5,1), opacity var(--motion-fast);
|
|
484
|
+
}
|
|
485
|
+
.w-item img, .w-item svg{display:block; width:100%; height:100%; object-fit:cover}
|
|
486
|
+
/* a look's picture at the share of the circle its size gives (looks.js pictureFill), standing on the circle's bottom */
|
|
487
|
+
.w-item .look-pic{display:flex; align-items:flex-end; justify-content:center; width:100%; height:100%}
|
|
488
|
+
.w-item .look-pic > svg, .w-item .look-pic > img{width:calc(100% * var(--look-fill)); height:calc(100% * var(--look-fill))}
|
|
489
|
+
/* the look worn that is not a favourite: kept for the row to turn back to */
|
|
490
|
+
.w-item.worn{border-style:dashed}
|
|
491
|
+
.w-item.on{border-color:var(--skin-eye); box-shadow:0 0 0 3px color-mix(in srgb, var(--skin-eye) 30%, transparent), var(--lift)}
|
|
492
|
+
/* hover buttons: the actions chosen in settings, in columns of up to three beside the pet */
|
|
493
|
+
.tools{position:fixed; left:0; top:0; z-index:4; display:grid; grid-auto-flow:column; gap:8px}
|
|
494
|
+
.tools[hidden]{display:none}
|
|
495
|
+
.tool{
|
|
496
|
+
position:relative; display:grid; place-items:center; width:38px; height:38px; padding:0; border-radius:50%; cursor:pointer;
|
|
497
|
+
background:var(--sheen), var(--glass); color:var(--text); border:2px solid var(--skin-ink); box-shadow:var(--lift);
|
|
498
|
+
}
|
|
499
|
+
.tool .ic{position:relative; display:grid; place-items:center}
|
|
500
|
+
.tool:hover{color:var(--skin-eye); border-color:var(--skin-eye); box-shadow:var(--halo), var(--lift)}
|
|
501
|
+
.tool svg{width:22px; height:22px; display:block}
|
|
502
|
+
/* the key badge sits off the button's lower right, clear of the icon */
|
|
503
|
+
.tool .badge{right:-14px; bottom:-9px}
|
|
504
|
+
/* a switch that is off, as a hover button and in the menu alike: its icon muted on a neutral grey face and ring, a little
|
|
505
|
+
see-through; the voice switch is also muted while the recognizer is not ready, and its hover button lit while hearing */
|
|
506
|
+
.tool.off{color:var(--muted); background:color-mix(in srgb, #9AA0A8 28%, var(--surface)); opacity:.75}
|
|
507
|
+
.tool.off:not(:hover){border-color:color-mix(in srgb, #9AA0A8 70%, var(--surface))}
|
|
508
|
+
/* not ready yet: muted, at the same line weight (a faded icon reads as a thinner one) */
|
|
509
|
+
.tool.waiting{color:var(--muted)}
|
|
510
|
+
.tool.live{color:var(--skin-eye); border-color:var(--skin-eye)}
|
|
511
|
+
/* held down: a ring closes in; when it is full the sentence is sent */
|
|
512
|
+
.tool.holding::after{
|
|
513
|
+
content:""; position:absolute; inset:-7px; border-radius:50%; border:2.5px solid var(--skin-eye); pointer-events:none;
|
|
514
|
+
animation:hold-ring var(--hold, .5s) linear forwards;
|
|
515
|
+
}
|
|
516
|
+
@keyframes hold-ring{from{transform:scale(.72); opacity:0} to{transform:scale(1); opacity:1}}
|
|
517
|
+
.tool.sent{animation:bump .36s var(--motion-pop); --bump:1.2}
|
|
518
|
+
:where(:root[data-motion="low"]) {.wall-glow, .wall-lens, .bubble.said, .w-item{transition:none}}
|
|
519
|
+
:where(:root[data-motion="low"]) {.bubble.status.pop, .status .status-icon svg, .status .status-icon svg *, .bubble.pop, .b-opt, .b-own, .d-body > *, .d-card, .d-key, .d-key.taps, .d-card.on .d-cardic, .d-field.shake, .b-own.shake, .d-pill.chosen, .caret, .menu :is(.m-grid, .m-rail) > *, .tools > *, .tool.sent, .tool::before, .tool::after, .tool .ic, .tool .ic::before{animation:none}}
|
|
520
|
+
:where(:root[data-motion="low"]) {.d-cards .d-card.on .d-cardic[class*="ic-persona_"], .d-cards .d-card.on .d-cardic .spout{animation:none}}
|
|
521
|
+
/* pointed at: every round button grows a little and its icon moves once in a way that fits it (the dress button
|
|
522
|
+
keeps its own colours and sparkles above); the run controls on the menu's left: the gear turns, the pause swells,
|
|
523
|
+
the power button is pressed */
|
|
524
|
+
.tool{transition:background var(--motion-fast), border-color var(--motion-fast), color var(--motion-fast), box-shadow var(--motion-fast), scale var(--motion-fast) ease}
|
|
525
|
+
.m-rail > .tool.power{transition:scale var(--motion-fast) ease}
|
|
526
|
+
.tool:hover{scale:1.15}
|
|
527
|
+
.tool:hover .ic svg{transform-origin:center; animation:var(--ic-hover, ic-bob) .5s ease-in-out}
|
|
528
|
+
[data-action="chat"]{--ic-hover:ic-bob}
|
|
529
|
+
[data-action="voice"]{--ic-hover:ic-pulse}
|
|
530
|
+
[data-action="roam"]{--ic-hover:ic-step}
|
|
531
|
+
[data-action="theme"]{--ic-hover:spin}
|
|
532
|
+
[data-action="sound"]{--ic-hover:ic-shake}
|
|
533
|
+
[data-action="hide"]{--ic-hover:ic-blink}
|
|
534
|
+
[data-action="worlds"]{--ic-hover:ic-lift}
|
|
535
|
+
[data-action="dress"]{--ic-hover:none}
|
|
536
|
+
.m-rail .tool:hover svg{transform-origin:center; animation:rail-gear .6s ease-in-out}
|
|
537
|
+
.m-rail .tool.run:hover svg{animation-name:ic-pulse}
|
|
538
|
+
.m-rail .tool.power:hover svg{animation-name:rail-press}
|
|
539
|
+
@keyframes ic-bob{40%{transform:translateY(-3px)} 70%{transform:translateY(1px)}}
|
|
540
|
+
@keyframes ic-pulse{35%{transform:scale(1.18)} 70%{transform:scale(.94)}}
|
|
541
|
+
@keyframes ic-step{25%{transform:translateX(-2px) rotate(-6deg)} 75%{transform:translateX(2px) rotate(6deg)}}
|
|
542
|
+
@keyframes ic-shake{20%,60%{transform:rotate(-10deg)} 40%,80%{transform:rotate(10deg)}}
|
|
543
|
+
@keyframes ic-blink{45%{transform:scaleY(.15)}}
|
|
544
|
+
@keyframes ic-lift{40%{transform:translateY(-3px) scale(1.06)} 70%{transform:translateY(1px)}}
|
|
545
|
+
@keyframes rail-gear{to{transform:rotate(180deg)}}
|
|
546
|
+
@keyframes rail-press{40%{transform:translateY(2px) scale(.9)}}
|
|
547
|
+
:where(:root[data-motion="low"]) {.tool:hover .ic svg, .m-rail .tool:hover svg{animation:none}}
|
|
548
|
+
/* hover hints (hints.js) in the pet window and the dress window, which takes this sheet too: drawn and animated as the
|
|
549
|
+
settings window's (console/styles.css .u-tip.hover-hint): fading in over 120 ms and out over 120 ms (hints.js LEAVE_MS) */
|
|
550
|
+
.hint{position:fixed; z-index:130; pointer-events:none; box-sizing:border-box; width:max-content; max-width:min(280px, calc(100vw - 16px));
|
|
551
|
+
background:var(--sheen), var(--glass); border:1px solid var(--line); border-radius:8px; padding:5px 9px; box-shadow:0 6px 18px -8px var(--shadow, rgba(0,0,0,.3));
|
|
552
|
+
font-size:12px; line-height:1.45; color:var(--text); overflow-wrap:anywhere; animation:hint-in 120ms ease-out}
|
|
553
|
+
.hint[hidden]{display:none}
|
|
554
|
+
.hint.leaving{animation:hint-out var(--hint-out) ease-in forwards}
|
|
555
|
+
@keyframes hint-in{from{opacity:0}}
|
|
556
|
+
@keyframes hint-out{to{opacity:0}}
|
|
557
|
+
:where(:root[data-motion="low"]) {.hint, .hint.leaving{animation:none}}
|
|
558
|
+
|
|
559
|
+
/* the size slider (scale-slider.js), on the dressing page and over the pet */
|
|
560
|
+
.pet-scale{position:relative; flex:none; height:22px; cursor:pointer; touch-action:none; outline:none}
|
|
561
|
+
.pet-scale > .ps-main, .pet-scale > .ps-tail, .pet-scale > .ps-fill{position:absolute; top:9px; height:4px; border-radius:2px}
|
|
562
|
+
.pet-scale > .ps-main{left:0; background:color-mix(in srgb, var(--muted) 35%, transparent)}
|
|
563
|
+
.pet-scale > .ps-tail{background:repeating-linear-gradient(90deg, color-mix(in srgb, var(--muted) 35%, transparent) 0 4px, transparent 4px 7px)}
|
|
564
|
+
.pet-scale > .ps-fill{left:0; background:var(--host-accent, var(--accent))}
|
|
565
|
+
.pet-scale > .ps-divider{position:absolute; top:4px; width:2px; height:14px; margin-left:-1px; border-radius:1px; background:var(--muted)}
|
|
566
|
+
.pet-scale > .ps-thumb{position:absolute; top:3px; width:16px; height:16px; margin-left:-8px; border-radius:50%; background:var(--host-accent, var(--accent))}
|
|
567
|
+
.pet-scale:focus-visible > .ps-thumb{outline:2px solid var(--host-accent, var(--accent)); outline-offset:2px}
|
|
568
|
+
.pet-scale.past > .ps-divider{background:var(--host-accent, var(--accent))}
|
|
569
|
+
/* stepped by key or wheel (scale-slider.js stepTo): the knob and the fill glide to each step, as they follow a drag */
|
|
570
|
+
.pet-scale.stepping > .ps-thumb{transition:left var(--motion-fast) ease-out, scale var(--motion-fast) ease}
|
|
571
|
+
.pet-scale.stepping > .ps-fill{transition:width var(--motion-fast) ease-out}
|
|
572
|
+
:where(:root[data-motion="low"]) {.pet-scale.stepping > .ps-thumb, .pet-scale.stepping > .ps-fill{transition:none}}
|
|
573
|
+
/* the size and transparency sliders over the body (pet-app.js stepSlider): no backdrop, as the look wheel. The bar is
|
|
574
|
+
drawn as the hover buttons are (the surface, the body's 2px outline, their shadow), the fill and the knob in the body's
|
|
575
|
+
accent; the percentage is a small button-like label over the knob */
|
|
576
|
+
.head-slider{position:fixed; z-index:6; display:flex; align-items:center; padding:32px 8px 10px}
|
|
577
|
+
.head-slider[hidden]{display:none}
|
|
578
|
+
.head-slider .pet-scale{height:28px}
|
|
579
|
+
.head-slider .pet-scale > .ps-main, .head-slider .pet-scale > .ps-tail{
|
|
580
|
+
top:6px; height:16px; box-sizing:border-box; background-color:var(--glass); border:2px solid var(--skin-ink); box-shadow:var(--lift);
|
|
581
|
+
}
|
|
582
|
+
.head-slider .pet-scale > .ps-main{border-radius:8px 0 0 8px; border-right:0}
|
|
583
|
+
/* the transparency slider has no stretch past a divider */
|
|
584
|
+
.head-slider .pet-scale > .ps-main:has(~ .ps-tail[hidden]){border-radius:8px; border-right:2px solid var(--skin-ink)}
|
|
585
|
+
/* past the divider: the same bar with a dashed middle, as the settings window's slider marks it */
|
|
586
|
+
.head-slider .pet-scale > .ps-tail{
|
|
587
|
+
border-radius:0 8px 8px 0; border-left:0;
|
|
588
|
+
background-image:repeating-linear-gradient(90deg, color-mix(in srgb, var(--skin-ink) 45%, transparent) 0 4px, transparent 4px 8px);
|
|
589
|
+
background-size:100% 4px; background-position:0 50%; background-repeat:no-repeat;
|
|
590
|
+
}
|
|
591
|
+
.head-slider .pet-scale > .ps-fill{left:4px; top:11px; height:6px; border-radius:3px; background:var(--skin-eye)}
|
|
592
|
+
.head-slider .pet-scale > .ps-divider{top:3px; height:22px; width:3px; margin-left:-1.5px; border-radius:2px; background:var(--skin-ink)}
|
|
593
|
+
.head-slider .pet-scale.past > .ps-divider{background:var(--skin-eye)}
|
|
594
|
+
.head-slider .pet-scale > .ps-thumb{
|
|
595
|
+
top:3px; width:22px; height:22px; margin-left:-11px; box-sizing:border-box;
|
|
596
|
+
background:var(--skin-eye); border:3px solid var(--surface); box-shadow:0 0 0 2px var(--skin-ink), var(--lift);
|
|
597
|
+
transition:scale var(--motion-fast) ease;
|
|
598
|
+
}
|
|
599
|
+
.head-slider .pet-scale:hover > .ps-thumb{scale:1.1}
|
|
600
|
+
/* held: dragged, or stepped by the wheel a moment ago */
|
|
601
|
+
.head-slider .pet-scale:is(:active, .stepping) > .ps-thumb{scale:1.2}
|
|
602
|
+
.head-slider .hs-value{
|
|
603
|
+
position:absolute; left:50%; bottom:calc(100% + 8px); translate:-50% 0; min-width:44px; padding:2px 8px; box-sizing:border-box;
|
|
604
|
+
border-radius:999px; text-align:center; white-space:nowrap; pointer-events:none;
|
|
605
|
+
font-size:12px; font-weight:600; line-height:16px; font-variant-numeric:tabular-nums;
|
|
606
|
+
background:var(--sheen), var(--glass); color:var(--text); border:2px solid var(--skin-ink); box-shadow:var(--lift);
|
|
607
|
+
}
|
|
608
|
+
.head-slider.entering{animation:rise-in var(--motion-base) var(--motion-pop-soft) backwards; --rise:8px; --rise-scale:.6}
|
|
609
|
+
/* a group of controls let go of glides back beside the body (pet-app.js follow, RETURN_MS) */
|
|
610
|
+
:is(.tools, .wheel, .head-slider, .m-grid, .m-rail).returning{transition:left var(--return-time) var(--motion-return), top var(--return-time) var(--motion-return), right var(--return-time) var(--motion-return)}
|
|
611
|
+
/* a size or transparency button while it holds its slider open (pet-app.js pinSlider): filled in the eye color, so it reads
|
|
612
|
+
apart from the eye-colored ring a hover alone draws, even with the pointer still on it */
|
|
613
|
+
.tool:is([data-action="size"], [data-action="fade"]).on{color:var(--surface); background:var(--skin-eye); border-color:var(--skin-eye)}
|
|
614
|
+
/* SLIDER_OUT_MS in pet-app.js */
|
|
615
|
+
.head-slider.leaving{animation:hs-out var(--slider-out) ease-in forwards; pointer-events:none}
|
|
616
|
+
@keyframes hs-out{to{transform:translateY(8px) scale(.6); opacity:0}}
|
|
617
|
+
:where(:root[data-motion="low"]) {.head-slider{animation:none}}
|
|
618
|
+
|
|
619
|
+
.fireworks{position:absolute; pointer-events:none}
|
|
620
|
+
|
|
621
|
+
/* ---------- motion levels: motion-level.js writes data-motion on the root (the settings window's 动态效果, `window.motion`) ---------- */
|
|
622
|
+
/* medium and low: nothing overshoots, and the decoration goes: the dialog's card hops and Persona icons' gestures, the chosen
|
|
623
|
+
pill's bump, the hover buttons' icon tricks and the dress button's show, the bump after a send; the look wheel settles without overshoot */
|
|
624
|
+
:root:not([data-motion="high"]) { --motion-pop: var(--motion-return); --motion-pop-soft: var(--motion-return); }
|
|
625
|
+
:where(:root:not([data-motion="high"])) {
|
|
626
|
+
.d-pill.chosen, .d-card.on .d-cardimg, .d-card.on .d-cardic, .d-card.on .d-cardic[class*="ic-persona_"], .d-card.on .d-cardic .spout,
|
|
627
|
+
.tool[data-action="dress"]:hover, .tool[data-action="dress"]:hover .ic, .tool[data-action="dress"]:hover::before, .tool[data-action="dress"]:hover::after, .tool[data-action="dress"]:hover .ic::before,
|
|
628
|
+
.tool.sent, .tool:hover .ic svg, .m-rail .tool:hover svg, .m-rail .tool.run:hover svg, .m-rail .tool.power:hover svg { animation: none; }
|
|
629
|
+
.w-item { transition-timing-function: var(--motion-return); }
|
|
630
|
+
}
|
|
631
|
+
/* low: everything outside the figure lands at once (the figure runs in its own frame); bubbles only fade in; what says
|
|
632
|
+
something is under way keeps going: the thinking dots, the waiting hourglass, a dialog's progress bar, a held button's ring */
|
|
633
|
+
:where(:root[data-motion="low"]) {
|
|
634
|
+
&, *:not(.figure-layer *), *:not(.figure-layer *)::before, *:not(.figure-layer *)::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; animation-delay: 0s !important; transition-duration: .001ms !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
|
|
635
|
+
.bubble.pop, .bubble.status.pop { animation: hint-in var(--motion-fast) ease-out !important; }
|
|
636
|
+
.status[data-kind="think"] circle { animation-name: status-think !important; animation-duration: 1.3s !important; animation-timing-function: ease-in-out !important; animation-iteration-count: infinite !important; }
|
|
637
|
+
.status[data-kind="think"] circle:nth-child(2) { animation-delay: .16s !important; }
|
|
638
|
+
.status[data-kind="think"] circle:nth-child(3) { animation-delay: .32s !important; }
|
|
639
|
+
.status[data-kind="wait"] svg { animation-name: status-wait !important; animation-duration: 2.8s !important; animation-timing-function: ease-in-out !important; animation-iteration-count: infinite !important; }
|
|
640
|
+
.d-bar.wait i { animation-duration: 1.2s !important; animation-iteration-count: infinite !important; }
|
|
641
|
+
.tool.holding::after { animation-duration: var(--hold, .5s) !important; }
|
|
642
|
+
}
|