Add browser voice input and speech output
Build and publish frontend / publish (push) Failing after 4s
Build and publish frontend / publish (push) Failing after 4s
This commit is contained in:
@@ -8,6 +8,15 @@ grep -q "request('/version')" index.html
|
||||
grep -Fq "credentials: 'same-origin'" index.html
|
||||
grep -q 'id="dialogue" aria-label="Dialoghistorik" role="log" aria-live="polite"' index.html
|
||||
grep -q 'id="message" name="message"' index.html
|
||||
grep -q 'id="microphone" aria-pressed="false"' index.html
|
||||
grep -q 'id="voice-status" role="status" aria-live="polite"' index.html
|
||||
grep -q "window.GameVoice.createVoiceController" index.html
|
||||
grep -q 'COPY voice.js /usr/share/nginx/html/voice.js' Dockerfile
|
||||
grep -q "SpeechRecognition || win.webkitSpeechRecognition" voice.js
|
||||
grep -q "submitMessage(text)" index.html
|
||||
grep -q "'screen-reader', 'Skärmläsare'" index.html
|
||||
grep -q "'game-voice', 'Spelets röst'" index.html
|
||||
grep -q "'text-only', 'Endast text'" index.html
|
||||
grep -q "event.key === 'Enter' && !event.shiftKey" index.html
|
||||
grep -q "request('/api/character/draft'" index.html
|
||||
grep -q "request('/api/world/draft'" index.html
|
||||
@@ -26,9 +35,11 @@ if grep -Eq 'id="(new-character|world-setup|shop|buy-offer|balance|inventory|pla
|
||||
echo 'The active player UI must not contain permanent data panels, forms, or action buttons.' >&2
|
||||
exit 1
|
||||
fi
|
||||
if sed -n '/<section id="play"/,/^ <\/section>/p' index.html | grep -q '<button'; then
|
||||
echo 'The game input must not require a separate send or action button.' >&2
|
||||
if sed -n '/<section id="play"/,/^ <\/section>/p' index.html | grep '<button' | grep -v 'id="microphone"' >/dev/null; then
|
||||
echo 'Only the microphone control may appear beside the game text input.' >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
node --test tests/voice.test.cjs
|
||||
|
||||
echo 'Frontend source checks passed.'
|
||||
|
||||
Reference in New Issue
Block a user