log: Vec<SessionFormattedLogEntry>,
sse_url_prefix: String,
links: Html,
+ scale: f64,
}
#[derive(Debug,Serialize)]
let src = SessionRenderContext {
table_colour: ig.gs.table_colour.clone(),
ctoken,
- gen : ig.gs.gen,
+ gen: ig.gs.gen,
log,
- table_size : ig.gs.table_size,
+ table_size: ig.gs.table_size,
player,
- defs : alldefs,
+ defs: alldefs,
uses,
- nick : gpl.nick.clone(),
+ scale: SVG_SCALE,
+ nick: gpl.nick.clone(),
sse_url_prefix,
ptoken: form.ptoken.clone(),
links: (&*ig.links).into(),
- load : serde_json::to_string(&DataLoad {
+ load: serde_json::to_string(&DataLoad {
players: load_players,
last_log_ts: timestamp_abbrev.unwrap_or_default(),
}).map_err(|e| InternalError::JSONEncode(e))?,
use crate::imports::*;
+pub const SVG_SCALE : f64 = 6.;
+
#[derive(Clone,Copy,Debug,Eq,PartialEq,Serialize,Deserialize,EnumString)]
pub enum PresentationLayout {
Portrait,
<svg id="space"
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 {{ table_size[0] }} {{ table_size[1] }}"
- width="{{ table_size[0]*6 }}" height="{{ table_size[1]*6 }}"
+ width="{{ table_size[0]*scale }}"
+ height="{{ table_size[1]*scale }}"
>
<rect fill="{{ table_colour }}" x="0" y="0"
width="{{ table_size[0] }}" height="{{ table_size[1] }}"/>