wip
This commit is contained in:
parent
a57ce2d840
commit
cd6f360628
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -21,7 +21,15 @@ jQuery(document).ready(function ($) {
|
||||
const draw = function() {
|
||||
const $screen = $('#screen');
|
||||
const $text = $('<div class="text">');
|
||||
$text.html($('#elem-text').val());
|
||||
let inside = $('#elem-text').val();
|
||||
|
||||
if ($('#elem-scroll-enable').is(':checked')) {
|
||||
const $wrapper = $('<marquee>');
|
||||
inside = $wrapper;
|
||||
$wrapper.html(inside);
|
||||
}
|
||||
|
||||
$text.html(inside);
|
||||
|
||||
let justifyContent = 'center';
|
||||
switch($('[name=elem-text-align]:checked').val()) {
|
||||
|
||||
@ -88,6 +88,19 @@
|
||||
align-self: stretch;
|
||||
}
|
||||
|
||||
.divide {
|
||||
margin-top: 30px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
|
||||
.bar {
|
||||
width: 100%;
|
||||
height: 1px;
|
||||
background: #333;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.form-group {
|
||||
label {
|
||||
flex-grow: 1;
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
# Configuration
|
||||
STUDIO_URL=http://localhost:5000 # Main Obscreen Studio instance URL (could be a specific playlist /use/[playlist-id] or let obscreen manage playlist routing with /)
|
||||
TARGET_RESOLUTION=auto # e.g. 1920x1080 - Force specific resolution (supported list available with command `DISPLAY=:0 xrandr`)
|
||||
|
||||
# Disable screensaver and DPMS
|
||||
xset s off
|
||||
xset -dpms
|
||||
@ -11,9 +15,11 @@ mkdir -p /home/pi/.config/chromium/Default 2>/dev/null
|
||||
touch /home/pi/.config/chromium/Default/Preferences
|
||||
sed -i 's/"exited_cleanly": false/"exited_cleanly": true/' /home/pi/.config/chromium/Default/Preferences
|
||||
|
||||
# Force specific resolution (supported list available with command `DISPLAY=:0 xrandr`)
|
||||
#FIRST_CONNECTED_SCREEN=$(xrandr | grep " connected" | awk '{print $1}' | head -n 1)
|
||||
#xrandr --output $FIRST_CONNECTED_SCREEN --mode 800x600
|
||||
# Resolution setup
|
||||
if [ "$TARGET_RESOLUTION" != "auto" ]; then
|
||||
FIRST_CONNECTED_SCREEN=$(xrandr | grep " connected" | awk '{print $1}' | head -n 1)
|
||||
xrandr --output $FIRST_CONNECTED_SCREEN --mode $TARGET_RESOLUTION
|
||||
fi
|
||||
|
||||
# Get screen resolution
|
||||
RESOLUTION=$(DISPLAY=:0 xrandr | grep '*' | awk '{print $1}')
|
||||
@ -39,4 +45,4 @@ chromium-browser \
|
||||
--window-position=0,0 \
|
||||
--window-size=${WIDTH},${HEIGHT} \
|
||||
--display=:0 \
|
||||
http://localhost:5000
|
||||
${STUDIO_URL}
|
||||
|
||||
@ -18,6 +18,18 @@
|
||||
.slide img, .slide video { {% if force_cover %}width: 100%;{% endif %} height: 100%; }
|
||||
.slide .text { width: 100%; height: 100%; color: white; font-family: 'Arial', 'sans-serif'; font-size: 20px; display: flex; flex-direction: row; justify-content: center; align-items: center; }
|
||||
.slide video { width: 100%; height: 100%; }
|
||||
@keyframes blink{50%{opacity:0;}}
|
||||
.cfx-blink{animation:1.5s linear infinite blinker;}
|
||||
.cfx-ffff-speed {animation-delay: 0.1s;}
|
||||
.cfx-fff-speed {animation-delay: 0.3s;}
|
||||
.cfx-ff-speed {animation-delay: 0.5s;}
|
||||
.cfx-f-speed {animation-delay: 0.8s;}
|
||||
.cfx-m-speed {animation-delay: 1s;}
|
||||
.cfx-s-speed {animation-delay: 1.3s;}
|
||||
.cfx-ss-speed {animation-delay: 1.5s;}
|
||||
.cfx-sss-speed {animation-delay: 1.8s;}
|
||||
.cfx-ssss-speed {animation-delay: 2s;}
|
||||
.cfx-sssss-speed {animation-delay: 3s;}
|
||||
</style>
|
||||
<script type="application/javascript" src="{{ STATIC_PREFIX }}js/utils.js"></script>
|
||||
<script type="application/javascript" src="{{ STATIC_PREFIX }}js/lib/is-cron-now.js"></script>
|
||||
|
||||
@ -234,6 +234,55 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h3 class="divide">
|
||||
Scrolling Effect
|
||||
</h3>
|
||||
|
||||
|
||||
<div class="form-group">
|
||||
<label for="elem-scroll-enable">Enable</label>
|
||||
<div class="widget">
|
||||
<div class="toggle">
|
||||
<input type="checkbox" name="elem-scroll-enable" id="elem-scroll-enable" />
|
||||
<label for="elem-scroll-enable"></label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="horizontal">
|
||||
<div class="form-group">
|
||||
<label for="elem-scroll-speed">Speed</label>
|
||||
<div class="widget widget-unit">
|
||||
<input type="text" id="elem-scroll-speed" name="elem-scroll-speed" maxlength="3" class="numeric-input chars-3" value="10">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="elem-scroll-direction">Direction</label>
|
||||
<div class="widget">
|
||||
<div class="radio-group">
|
||||
<input type="radio" id="elem-scroll-direction-left" name="elem-scroll-direction-left" value="left">
|
||||
<label for="elem-scroll-direction-left" class="btn btn-neutral">
|
||||
<i class="fa fa-arrow-left"></i>
|
||||
</label>
|
||||
<input type="radio" id="elem-scroll-direction-right" name="elem-scroll-direction-right" value="right">
|
||||
<label for="elem-scroll-direction-right" class="btn btn-neutral">
|
||||
<i class="fa fa-arrow-right"></i>
|
||||
</label>
|
||||
<input type="radio" id="elem-scroll-direction-down" name="elem-scroll-direction-down" value="down">
|
||||
<label for="elem-scroll-direction-down" class="btn btn-neutral">
|
||||
<i class="fa fa-arrow-down"></i>
|
||||
</label>
|
||||
<input type="radio" id="elem-scroll-direction-up" name="elem-scroll-direction-up" value="up">
|
||||
<label for="elem-scroll-direction-up" class="btn btn-neutral">
|
||||
<i class="fa fa-arrow-up"></i>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<h3 class="divide">
|
||||
Layout
|
||||
</h3>
|
||||
@ -252,7 +301,7 @@
|
||||
<label for="elem-single-line">Single Line Only</label>
|
||||
<div class="widget">
|
||||
<div class="toggle">
|
||||
<input type="checkbox" name="elem-single-line" id="elem-single-line" value="1"/>
|
||||
<input type="checkbox" name="elem-single-line" id="elem-single-line" />
|
||||
<label for="elem-single-line"></label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user